« first day (2302 days earlier)      last day (24 days later) » 

12:00 AM
RELOAD! There are 6213 unanswered questions (89.9076% answered)
 
12:18 AM
@Peilonrayz Yeah. I remember Jeff Atwood talking about making the experience on SO better for newcomers probably close to 2 years ago. Nice to see something concrete taking shape.
 
1:08 AM
0
Q: Java Unzipping a file

Jacqueline P.I am completing a study problem to learn how to unzip file using Java. The problem requirement is : The main method accepts a list of arguments. The first argument, resultFileName, is the name of the resulting file; The remaining arguments are the names of files for fileNamePart. Each fileNameP...

0
Q: How to optimize code below by getting rid of redundant?

NishantMy code below is to calculate ProductFunction based on some values of Object Product. Method getProductFunctions in InternalProductMapper and ExternalProductMapper call functions in ProductFunctionCalculator to calcuate the value of ProductFunction. According to me its not possible to have a sin...

 
2:00 AM
This suits better in code review. — Austin 16 secs ago
@Austin Stub code is off-topic on Code Review. Please don't blindly push people to post off-topic questions on sites you clearly know nothing about. — Peilonrayz 26 secs ago
 
2:26 AM
0
Q: Django views - Is this standard?

Bo WorkI have made a website where people write about their day and see it analyzed. In particular, the website takes event titles and groups them together if they have any common words (after stemming the event titles). The class that is most important is EventAnalysis, and its most important methods a...

 
 
2 hours later…
4:27 AM
Monking
@Peilonrayz That's pretty decent for a start.
 
Monking
 
> Controlling for these confounders, when a first time question asker uses the wizard, their question is about 6% more likely to be good quality and 20% less likely to be bad quality.
But that's weighed and I'm not sure whether or not they did that right. I'm not a statistician.
 
 
1 hour later…
5:46 AM
If you'd like to optimize your code, you can post it here and ask for a review. — Emma 49 secs ago
 
 
1 hour later…
6:55 AM
possible answer invalidation by LGSon on question by LGSon: codereview.stackexchange.com/posts/226028/revisions
 
7:25 AM
0
Q: How do we fetch record from database using spring batch based on id

agamjain14My current project successfully reads csv data and stores the entries in postreSQL My question is how do I fetch the record based on Id with using best practices. BatchConfig.java package com.csvpostgresspringbatch.config; import com.csvpostgresspringbatch.dao.BankDAO; import com.csvpostgre...

 
7:53 AM
Monking
 
@CaptainObvious Use a dog instead.
2
 
1
Q: Asking for feedback on DFS Detect Cycle algorithm in swift language?

andreadotlopezI'm reviewing my algorithms fundamentals by writing them in swift. I was able to get this version of the Detecting Cycles using the iterative DFS algorithm to work for a number of test graphs but am not convinced that it's correct or efficient. Can anyone help me make it better or validate the lo...

0
Q: A future-oriented code upgrade

khashashinSince I've "working" code, that must be extended I hope Code Review is the right place to ask for that. I've to pass some data from incoming object, but I cannot be sure about the values that this object contains. Some(or each) of the object value may be defined or not. I'll not end the function...

 
8:23 AM
0
Q: LeetCode: Group Anagrams C#

Giladhttps://leetcode.com/problems/group-anagrams/ Given an array of strings, group anagrams together. Example: Input: ["eat", "tea", "tan", "ate", "nat", "bat"], Output: [ ["ate","eat","tea"], ["nat","tan"], ["bat"] ] Note: All inputs will be in lowercase. The order of your output does not...

 
@UweKeim , OP ask for code review. I guess code review is off topic on SO. I just answered the fires part of question. I hope will be enough to help this user and other users. Regards. — dani herrera 41 secs ago
 
9:30 AM
possible answer invalidation by shorif2000 on question by shorif2000: codereview.stackexchange.com/posts/226579/revisions
 
Kaz
Monking @all
 
9:42 AM
0
Q: refactoring python function to make it more redable & unit testable

anekixI have a function whose responsibility is to send a push notification to a user.I call this function from a view in flask framework. NOTE: This is not a generic or opinion based question & i have added python tag as my implementation is in python. also i have read multiple articles around refact...

 
9:55 AM
possible answer invalidation by shorif2000 on question by shorif2000: codereview.stackexchange.com/posts/226579/revisions
 
10:17 AM
is "10L rows" 1 million (i.e. 1e6) rows? people outside india don't really use lakh, you're better off sticking to SI prefixes on stackoverflow... reading a 1M row CSV file in pandas on my laptop takes approx 25ms per numeric column and 100ms per text column, i.e. 0.3 seconds for 4 numeric and 2 text columns. there are lots of articles about optimising Python/numeric code, if you can't find anything maybe post another question here or on codereview.stackexchange.comSam Mason 53 secs ago
 
10:37 AM
@Duga Rolled back.
 
11:29 AM
You'll have better luck on codereview.stackexchange.com. — npinti 29 secs ago
 
11:48 AM
Unfortunately, your question is too broad / off topic for SO format. Try CodeReview SE instead. — Ron 24 secs ago
 
12:06 PM
Please direct your post to CodeReview SE while avoiding the cross-posting. — Ron 28 secs ago
 
12:19 PM
-1
Q: The Randomized algorithm Parody

Arpit kingI was reading CLRS and I was stuck at question 5.1-2. Describe an implementation of the procedure RANDOM(a,b) that only makes calls to RANDOM(0,1).What is the expected running time of your procedure, as a function of a and b? The solution written here provides a complexity of O(lg(b-a)). http:...

 
12:39 PM
0
Q: Testable class/interface in embedded software written in C++

Stanislav PankevichI would like to collect feedback on possible solutions for creating testable classes/interfaces. In a normal non-embedded C++ development we can use references/pointers and forward declarations to achieve dynamic polymorphism (see "Solution with references" below). However with the embedded con...

 
12:51 PM
@Kaz TWO DAYS IN A ROW?!?!?!?!?
 
0
Q: Builder pattern in C# supporting subclassing with nested classes

S'pht'Kr[Posted yesterday on Software Engineering, but was apparently "disappeared"...maybe better here] Background: I am just starting to get my head around the idea of separating the domain model from the persistence layer (per Uncle Bob), service layer/IoC/separation of concerns/dependency injection,...

 
1:30 PM
possible answer invalidation by Karl Richter on question by Karl Richter: codereview.stackexchange.com/posts/189662/revisions
 
2:01 PM
@DerKommissar lol
 
2:20 PM
@CaptainObvious For those of you that can see an RBA were my comments off on this one?
Just curious, does closing questions kill zombies?
 
2:36 PM
This post can't be migrated, as it currently stands. Read the Code Review How to ask guidelines, then post a new question there that fits those guidelines. For example, the title of the post here is not a good fit for CR. — Martijn Pieters ♦ 23 secs ago
There is a CodeReview SE site. Avoid cross-posting. — Ron 21 secs ago
 
@pacmaninbw The unanswered percentage only counts open questions.
 
If you code is working correctly you may want to ask for it to be reviewed over on Code Review. — Dave 30 secs ago
I'm sorry I didn't know that there is a code review and yes my code is actually working. — John Doe 46 secs ago
 
2:57 PM
-2
Q: Why free() is generating an error when I use __strtok_r() in C. Is there any alternatives to __strtok_r()?

Suraj SharmaI am using the dynamically allocated string named *buffer to store the contents of the string time_digital, in order to tokenize the string using __strtok_r() function defined in #include<string.h>. I have written the following logic to tokenize the string time_digital which contains the time i...

0
Q: Twig macro to generate a table

Ismael MiguelBasically, I'm lazy. And so, since I don't want to write multiple times the same table HTML, I've made a very ... convoluted macro. {% macro table(rows, options = {}) %} {% set default = { 'width': '100%' } %} {% set options = default|merge(options) %} <table {%...

 
3:09 PM
Greetings, Programs.
 
Monking
Happy Friday
 
I'm voting to close this question as off-topic because it belongs on codereview. — TheIncorrigible1 30 secs ago
 
@Duga I guess it isn't worth trying to suggest that user utilize different reasons for voting to close, given username :/
 
Monking
 
3:36 PM
0
Q: Fast way to calculate source response using Green's function

Bahauddin OmarI am a newbie in the scientific computing in python. The function I am trying to calculate is the response of the wave equation for a given source term (For reference, See: Equation 11.67 in https://webhome.phy.duke.edu/~rgb/Class/phy319/phy319/node75.html). To give context, the term phi in the...

0
Q: Indexing documents in Elastic Search using Refresh.True - Performance hit and how can it be improved?

George TaskosI have an AWS Elastic Search server. Using mapping template and an index strategy. { "index_patterns": "users*", "order": 6, "version": 6, "aliases": { "users": {} }, "settings": { "number_of_shards": 5 }, "mappings": { "_doc": { "dynamic": "strict", "pro...

1
Q: Immutable builder and updater

t3chb0tThere aren't enough questions about creating immutable objects... so why not try it again with another approach. This time, it's a builder that maps properties to constructor parameters. Properties are selected via the With method that also expects a new value for the parameter. Constructor param...

 
If your code works and you seek improvement, you should consider posting the question at Code ReviewWiktor Stribiżew 21 secs ago
 
3:50 PM
anyone has a suggestion how to proceed with this one?: codereview.stackexchange.com/questions/200509/…
 
0
Q: PHP pthreads async optimisation and code flaws

John DoeAfter tinkering/testing stuffs for a few days with pthreads I manage to write a script from scratch that actually works for my needs. The point of my script is to run async like 500-1000 threads and keep creating new ones immediately when one is available. However because I'm not an expert in PHP...

 
@dfhwze I added a comment for Adriano
 
@SᴀᴍOnᴇᴌᴀ I would vote on that comment, but I'm out of comments for today :p
 
@dfhwze maybe you should have thought about that before using all of your votes ;) ... I guess you could wait 8 hours to do that
 
@SᴀᴍOnᴇᴌᴀ at least, I'm not out of stars yet! have one for free :p
 
4:04 PM
@dfhwze way to be! ★
@dfhwze actually that question does look like it is a code snippet ... maybe it should be closed...
 
@dfhwze Napalmd the thing for you.
 
I don't know what PlayerPrefs is, nor enduranceMedal...
 
@SᴀᴍOnᴇᴌᴀ PlayerPrefs is about preferences I think, like a player configuration.
 
-1
Q: I have a problem in post and pre increment operators in c. How the statement will be evaluated if its a + ++a + ++a

user529767For a =2, the answer is 10. But my question in unary operator is higher precedence than arithmetic operators. So why doesn't it be 12? int i = 2,b; b = i + ++i + ++i; printf("%d\n", b);

 
An enduranceMedal is awarded for playing long enough, usually.
@CaptainObvious Holy mother of off-topic questions.
 
4:35 PM
0
Q: Dynamic fiel access in Haskell

mkUltraI have to transform a response into the internal Coordinate record, some of the fields are lists and I need to handle empty lists case. Records: newtype GeoResponse = GeoResponse { results :: [ResultResponse] } deriving (Eq, Show, Generic) newtype ResultResponse = ResultResponse ...

 
@NikosOikou Here is another question: Convert a set into a string. I am waiting for your solution if you lost it or something please tell me so I stop keep asking it from you! — Bubbaloo 45 secs ago
@NikosOikou Here is another question: Converting a set into a string. I am waiting for your solution if you lost it or something please tell me so I stop keep asking it from you! — Bubbaloo 12 secs ago
 
4:55 PM
1
Q: Converting a set into a string

BubbalooThe input is a set of alphabets. The output is a string of 32 in length. For any letter in the set if it is preceded by a '¬' we replace the n-th character in our output string with '0', such that n is the position of the letter in the alphabets. If it is not preceded by a '¬' and was there in ...

 
5:14 PM
-2
Q: Rewrite a factory method in Swift forcing parameters checking

Lorenzo BI've created a static method in Swift that acts as a factory method for creating MyViewController instances. extension MyViewController { static func create(with configuration: Configuration, kind: Kind, delegate: MyViewControllerDelegate? = nil) ->

1
Q: How could I have made this Powershell script that executes robocopy code better

BeeI am trying to get better at Powershell and was wondering if I could get some advice on how to make this code more efficient/cleaner/anything. This code is intended to launch three batch windows running robocopy at the same time with unique log names. I looked into using a foreach loop but wasn...

0
Q: Regex XML validator

Geza KerecsenyiI have written a Regex to validate XML/HTML, along with any attributes. It aims to: Match any XML-like text Not match any unclosed tags Adapt for any spacing, newlines, etc. Be as generous as possible: match as much as possible. I initially created this to validate API requests I was making, ...

 
5:34 PM
-1
Q: Easiest way to get notified for a Publisher?

J. DoeThe code I am using now all the time is written below. For my feeling, it could be shorter and better. Why is the cancellable property needed? Why do I need to post a notification through NotificationCenter.default? Why can't this directly be done on the publisher itself? import Combine import U...

 
6:13 PM
1
Q: Javascript Tree Class

Alex FI got caught in the trap of implementing my own data structure. I'm mostly looking for advice on how to make this code more idiomatic, but also functionality that might be missing from this class, or that isn't necessary. I would also like thoughts on how idiomatic the traverse function is, and i...

 
6:39 PM
@dfhwze How is it off-topic? Looks on-topic to me and you've suggested a user answer it (which is only something you do to on-topic questions)
Also what context is missing? I could probably answer the question with what's there, and I know nothing about C#...
It's quite disappointing that even when asked how it's off-topic you ignored it.
 
@Peilonrayz I think it's slightly off-topic because there are some variables that are used in the code that we don't know what they're doing. Although I think the question could've stayed open and easily answered.
 
I forget we're not allowed code snippets on CR, lol
Actually hate this reason cause everyone here filpflops on it so much.
 
I think it's context dependent. In this case, I don't think the missing variables creates confusion regarding the context, it's clear what the code does
 
I previously went to meta with a question where we knew nothing, no variables were defined and all functions were undefined and people were like that's ontopic. And now one missing T foo and everyone VTC...
 
@JohnHarrison: next time, please post your work inside the question. Answering it yourselft either to summarize the responses and/or to show that you eventually got it is fine. But, while there is a bit of gamification here, this is not a contest; it's simply a Q & A site. Also, if you already have a working solution that you're looking to see improved, consider posting it to Code Review instead. — Scott Sauyet 57 secs ago
 
7:00 PM
@Peilonrayz Depends on the weather I guess.
 
Yeah I know, not everyone has the same criteria for VTC. I feel like these divergences in opinions will only continue to grow with the growth of the site
Okay so, whenever a mod can take a look at this chatroom and the associated post/comments, please do : https://chat.stackexchange.com/rooms/97785/discussion-between-john-doe-and-ieatbagels

Small warning, the third user, KIKO Software, claims he's indeed been flooded by emails so I would appreciate if we could thread the situation lightly.
Because I don't feel like potentially getting flooded myself.
 
There's 5 missing variables, 3 of which are just sprites to be put on enduranceImage. The PlayerPrefs is as needed as the calling code if this were provided as a function leaving enduranceMedal which is the only somewhat strange thing there.
 
Right now the situation is defused, it'd be okay if it stayed this way, but surely this goes against community rules and I don't really know what to do about it
 
@Peilonrayz Yes I handled this question in an unorthodox fashion. Not my best intervention this week o_0
 
7:16 PM
@IEatBagels I've just read over a bit of that, yeah can a @mod (@Vogel612 @rolfl @Malachi) look into this. I think it may be above mod level tho.
 
7:26 PM
@IEatBagels could you point me to the location of the claim in a flag?
 
I just did
It's all in the post related to the chatroom I linked above
 
ya, I didn't spot it before
thanks
 
Wow...that's a lot to unpack. I suggest us 'mere mortals' (wink) let the mods do what they need to do.
 
the guy uses extortion tactics, that's a fellony in any country
 
I'm this close: '' to telling him to spam my inbox, because I know how to alert the FBI to extortionists and spammers.
But, I won't feed the troll.
 
7:35 PM
the guy brags about extorting ppl, and he admits on spamming a user here ... why go lighthearted about it?
 
I want to politely say again, let's allow the mods to handle this. (It looks like Vogel is on it.) The chatroom discussion and claims have serious consequences, so let's just drop it. Stack Exchange will do what Stack Exchange needs to do.
4
 
Yeah, I just flagged a comment.
I'm sure Vogel and SE can handle it pretty well.
And KIKO can set up an IP block or inbox rules, depending on who owns his email, to stop the emails.
 
Thank you @Vogel612.
 
~sigh why are there people like that?
 
For good to exist evil must also, else there would be nothing to compare it to.
 
7:44 PM
@Vogel612 back in the day in mIRC there were ppl that attacked entire university networks like this
 
@dfhwze yea I know, that doesn't answer the question.
Not that it was really a question in the first place.
more like a lamentation
 
It's a disappointing observation.
As I say (because one of my best friends hates the phrase): it be like that sometimes.
 
I'm saying the internet is full of these ppl
 
Anonymity is a cruel drug.
Causes people to do things they normally wouldn't due to a fear of punishment, on the internet such fear is often easy to alleviate.
It makes people feel "cool" and "powerful."
The sheer understanding that "I could ruin your life" encourages them to consider it.
 
Yeah the thing degenerated pretty quickly, at least he seemed to have agree to stop harassing the other user.
 
7:52 PM
The initial comment that triggered him was not disrespectful at all
 
That's what I tried to say, it's kind of a norm
 
You see now why I don't comment anymore :p
4
 
8:22 PM
@dfhwze I haven't heard mIRC in a long time...lol
or any IRC
 
@Malachi same here, wonder it still exists.. we had DC++ for a while.
 
0
Q: Optimizing away log function calls depending on global log level

xlxs4I am a member of a university team designing a nanosatellite. We decided to implement our own (more lite) logging library to use, instead of, say, Google's glog, spdlog, plog and Boost::Log. The concept of different log levels is introduced, as a means of dividing the log messages into subcateg...

 
8:39 PM
@Peilonrayz FWIW your comment convinced me to retract my VTC on that sprite question... I see another user has VTC'd recently so it is back up to 3 :/ darn weather
 
@IEatBagels Ok so until literally just now I did not think your name was "I Eat Bagels" and I was wondering how you weren't banned. Turns out I just can't read lmfao
 
@DerKommissar ಠ_ಠ did you think it had an h before ate?
 
No. I won't share what I thought it was but I did not think the last word was "Bagels".
 
Because if the last word were what I thought it was, well you would understand why I was confused they were not banned.
 
8:47 PM
Could you add an asterisk where you misread? Because I can't see it.
 
:p
 
Well imagine there were no "g's" in the word, and that the last 'e' was not present.
 
Questions about coding style would be more appropriate for Code Review. But they want you to post the full code, then they'll critique it and show better ways to write it. — Barmar 1 min ago
 
And there was an extra L, maybe?
 
8:49 PM
@dfhwze that reminds of a tattoo a former colleague has: /* no comment */
 
Maybe...
 
XD
 
Now I am thinking of an SNL skit involving Alec Baldwin
 
@Peilonrayz I withdrew my close vote because of your passion, but I do feel PlayerPrefs could have been pivotal for the review. Perhaps that class could have cached some order of medal counts.
 
@SᴀᴍOnᴇᴌᴀ RIP :/
@dfhwze Change the first 4LOC to function (int easyMedal, int mediumMedal, int hardMedal, int insaneMedal, Sprite bronzeSprite, Sprite silverSprite, Sprite goldSprite, TMedal enduranceMedal) and I see no reason you'd need to know any more. You wouldn't need to know what Sprite is and PlayerPrefs has vanished as it has nothing to do with the CR code other than to provide some ints
 
8:55 PM
We could challenge why it has to vanish, or why no intermediate structure was called into existence
 
Yeah, but you don't need that stuff. That's just the cherry on the top of the cake.
 
I only hope that the commenter answers so the question could be dealt with as it should have
 
@dfhwze maybe within a few days ... commenter has "seen" pages on CR and SO in the past 1-2 days
 
9:11 PM
0
Q: Quick Sort in C

sturcotte06I'd like to know if there's any issues with this implementation of qsort_r (which is not available in all implementations, so I'm trying to provide one that allows to compare values in a dynamic environment) and whether it could be improved upon. typedef int32_t compare_fn(void *data, const void...

 
9:47 PM
 
10:10 PM
0
Q: Compiling dependency files: Linker Warning

SpacefishI adapted a makefile to re-compile for changed header files by generating a list of dependencies. The code framework already existed and all I had to do was adding a little bit of code for the compiling rules. Now I get linker warnings. Which is confusing because when I compile my program, the li...

 
 
1 hour later…
11:28 PM
0
Q: Calculate Cash Flow

rafael gonzalezI have written a cashflow calculator. Any suggestions on how to improve the code below? Income and expenses have a similar pattern. #ifndef MAINWINDOW_H #define MAINWINDOW_H #include <QMainWindow> #include <QStringListModel> #include <QSettings> namespace Ui { class MainWindow; } class MainWi...

 
possible answer invalidation by sturcotte06 on question by sturcotte06: codereview.stackexchange.com/posts/226717/revisions
 

« first day (2302 days earlier)      last day (24 days later) »