« first day (1048 days earlier)      last day (2974 days later) » 

7:00 PM
I wonder what happens if I pull the power cord... do I still have a battery or it's fried?
 
Can someone improve my code... NO. This is not codereview. — Bob Malooga 5 secs ago
this isn't a code review site, also, fix your indentation if you expect people to read your code. Additionally, its never a good idea to use any kind of block statement without brackets, such as you had done with your while loop — redFIVE 33 secs ago
 
@Duga and if you don't expect people to read your code, fix your indentation anyway
 
@Duga Take a chill pill dude
 
lol
@Mat'sMug no boom now, boom later. There's always a boom — Richard U 39 secs ago
 
http://www.commitstrip.com/en/2016/03/17/too-full-stack/
CommitStrip
Too Full Stack
CommitStrip
1458241468
5
 
7:15 PM
"too full stack" .... the word is "overflow" - Stack Overflow
 
If the code works as intended, this would be a better fit for the Code Review site. This is probably too broad for Stack Overflow if there is not a specific problem or question involved. — Phrancis 20 secs ago
 
1
Q: Custom Web Api asynchronous filter implementation

tribetFollowing the tutorial from Filip W's blog, I've ended up creating my own implementation for a custom ActionFilter. This logs the execution name, action, parameters and elapsed time of every ApiController in my solution. The post is a bit old (2013), that's why I'm still thinking it must be a ...

 
If (and only if) the above code currently works as intended, this would be a better fit for the Code Review site. This is probably too broad for Stack Overflow unless there is a specific problem or question. — Phrancis 45 secs ago
 
hahahaha
This is the first Stack Exchange post in six years that I'm on the network that I'm forwarding to the wife. — dotancohen 2 days ago
 
7:30 PM
0
Q: Java syncronisation

Sumit BahadurI am working with synchronization for the first time. I have a code below that i have to implement in my current work. I wanted to know if I am doing it right or am I making a mistake. whenever new list of data is downloaded, NewDataArrived() is called. This method then calls the ListData() tha...

 
@CaptainObvious Let me fix that grammar real quick
That indentation is seriously FUBAR lol
 
Guys... remember me. ;-)
 
hi @ambigram_maker!
 
@ambigram_maker hey, long time no see chat!
 
7:38 PM
monking!
I made a Sudoku solver
It works better than expected.
:-)
A funny thing happened though...
I googled for the "hardest sudoku" : google.co.in/…
Fed the first result into my code...
Found out it wasn't even a valid Sudoku.
lol
 
14
Q: How do I solve the world's hardest sudoku?

durron597This question is posted under the guidelines Don't worry too hard about restricting or regulating anything that isn't turning into a problem yet. If you don't agree that this question is on topic, please go to that meta thread and talk about why you feel that way!* Solve this Sudoku. Post how yo...

is it that puzzle? ^^
 
Yeah... that one
Now...
 
it's actually solvable ;-)
 
For a Sudoku to be valid, it must have only 1 solution
 
hmm
 
7:42 PM
But guess how many my code found...
;)
Drum roll please....
335
 
uh
11
A: How do I solve the world's hardest sudoku?

EmrakulFor this puzzle, while it has one and only one solution, no known patterns work on it, other than a slightly more intelligent guess-and-check. The number of steps one has to look ahead in order to reduce away clues is the metric here, and this puzzle needs nine sequential guesses to reach a solva...

solution here ^
 
Yeah... it is one of the possible 335
My code is on GitHub.
Will post it here.
 
@ambigram_maker are all 335 actual valid solutions?
 
I smell a bug
 
I am 57% sure.
3
 
7:45 PM
or a scam
lol
 
lol
I think there might be a bug.
Ok... You guys will be my witness if my code turns out to be alright. Deal?
 
so, it works as expected, except it finds 335 valid solutions for that sudoku?
 
yes
for valid sudokus, it finds only one
 
emphasis on "valid"
 
Yeah... I checked them
offline and online
 
7:47 PM
wut
 
So... deal?
 
...IDK, sounds a bit like "find the bug" to me
 
er... maybe
:)
 
0
Q: Initialization lock for singleton

MLProgrammer-CiMI'd like someone to double-check my use of Atomic primitives, because multi-threading is hard. What I don't want to do is locking the whole get method, or having too many pre-checks per get() call. private final static AtomicReference<T> REFERENCE = new AtomicReference<>(); private final stati...

 
My code is almost a translation of Peter Norvig's code... link
I think we all know his reputation and credibility, right?
 
7:50 PM
show me one of the 335 solutions that aren't this one:
 
it is one of them
 
@Mat'sMug that.
 
ive checked
 
dang, you're right
862 || 751 || 349
943 || 628 || 157
571 || 493 || 286
============
159 || 387 || 624
386 || 245 || 791
724 || 169 || 835
============
217 || 934 || 568
438 || 576 || 912
695 || 812 || 473
 
So.. deal?
 
7:52 PM
fine by me
 
After you guys give me the green signal, I'll comment on that question on Puzzling.SE
 
no wait
 
bottom-left corner
 
what?
 
7:53 PM
they moved the 1
the 2nd solution isn't valid
 
> Note: This puzzle has the 1 on the 7th line in a different position as the question's. This puzzle has multiple solutions.
wtf
 
Yeah.. but my ones are valid though... check one of them
+-----------------------+
| 8 1 2 | 7 5 3 | 6 9 4 |
| 9 4 3 | 6 2 8 | 1 7 5 |
| 5 7 6 | 4 9 1 | 2 8 3 |
|-------+-------+-------|
| 2 3 5 | 9 6 7 | 8 4 1 |
| 1 8 9 | 3 4 5 | 7 2 6 |
| 7 6 4 | 1 8 2 | 5 3 9 |
|-------+-------+-------|
| 4 5 1 | 2 7 9 | 3 6 8 |
| 6 2 8 | 5 3 4 | 9 1 7 |
| 3 9 7 | 8 1 6 | 4 5 2 |
+-----------------------+
 
oh sure @Quill, you go over to that question and leave an answer but don't upvote me? what's wrong with my answer? lol TTGH
 
9 o'clock the 5 is moved, solution isn't valid
 
7:55 PM
Oh.. dang... debugging
 
:)
 
bye... and thanks!! really
:)
Wait... wrong question...
Oh.. its wrong.. ur right
sorry
 
@BernardMeurer fite meee
 
Ripe zombie; open question with answers, at least one answer having score 0, no answer having score > 0: Function simulating single elevator movement
 
Time for a Sudoku Solver tester
 
8:01 PM
Ah... all this time.. I've been putting the 5 (9'o clock) diagonally to 7, not below it. Gives only 1 solution. :)
It works.
+-----------------------+
| 8 1 2 | 7 5 3 | 6 4 9 |
| 9 4 3 | 6 8 2 | 1 7 5 |
| 6 7 5 | 4 9 1 | 2 8 3 |
|-------+-------+-------|
| 1 5 4 | 2 3 7 | 8 9 6 |
| 3 6 9 | 8 4 5 | 7 2 1 |
| 2 8 7 | 1 6 9 | 5 3 4 |
|-------+-------+-------|
| 5 2 1 | 9 7 4 | 3 6 8 |
| 4 3 8 | 5 2 6 | 9 1 7 |
| 7 9 6 | 3 1 8 | 4 5 2 |
+-----------------------+
My code works fine... my hands are too shaky. :)
 
I sense a disturbance in the Force... a CR post is rising.
 
?
what?
 
@Mat'sMug Are your zombie senses tingling?
 
334 Sudoku solutions just screamed in horror as they disintegrated
4
 
lol
ok.. posting my code
 
8:17 PM
0
Q: Sudoku Solver - uses DFS and Constraint Propagation

ambigram_makerDisclaimer: My code is translated from Peter Norvig's Python code. This simple code uses only two techniques: Constraint Satisfaction and Depth-First-Search. Backtracking is not implemented. Here's the code: Board.java package core; import java.util.*; import static core.Constants.*; /** ...

Good night... I'll talk tomorrow.
 
I'm voting to close this question as off-topic because it should be made on Code Review — Petter Friberg 6 secs ago
 
1
Q: Sudoku Solver - uses DFS and Constraint Propagation

ambigram_makerDisclaimer: My code is translated from Peter Norvig's Python code. This simple code uses only two techniques: Constraint Satisfaction and Depth-First-Search. Backtracking is not implemented. Here's the code: Board.java package core; import java.util.*; import static core.Constants.*; /** ...

0
Q: Unit Tests for a Redshift Wrapper Class

flybonzaiI'm somewhat new to TDD and Unit Testing, but I've written a suite of unit tests to check my functionality. The basic classes automate simple load and unload operations from s3 and redshift, and allow one to use custom sql if needed. I've also implemented an execute method which will try an ope...

 
@Duga I got 99 flags a day, keep em coming.
 
I believe this is Problem 5, not Problem 4... — Herminator Dec 5 '12 at 9:31
lol
 
As long as it works for that solution ^^
 
8:31 PM
99 little flags a day, 99 little flags. Flags a post, flag's helpful, 110 little flags a day...
 
^^
That's how I got my 99, yes.
A lot of them expire though.
 
8:45 PM
This question rather belongs to Code Review Stack ExchangeSzeki 8 secs ago
 
> Showing 229 changed files with 36,206 additions and 27,784 deletions.
#CatchingUp
 
Not in one commit I hope?
 
lol
 
> I'm 10th grader
What's the average age of a 10th grader?
 
no clue, but pic seems to agree with statement
 
8:47 PM
That's highly, highly inefficient code.
 
If you plan to ask on code review, make sure you format this first. — James Root 31 secs ago
 
if(x==1 && x1!='X' && x1!='O')if(a%2==0)x1='X', a++, i++;
                              else x1='O', a++, i++;
if(x==2 && x2!='X' && x2!='O')if(a%2==0)x2='X', a++, i++;
                              else x2='O', a++, i++;
if(x==3 && x3!='X' && x3!='O')if(a%2==0)x3='X', a++, i++;
                              else x3='O', a++, i++;
if(x==4 && x4!='X' && x4!='O')if(a%2==0)x4='X', a++, i++;
                              else x4='O', a++, i++;
if(x==5 && x5!='X' && x5!='O')if(a%2==0)x5='X', a++, i++;
 
@Mat'sMug no
 
^^
 
@Mast Here: bfy.tw/4oBr
 
8:49 PM
gosh that's terrible
 
Does he even know how a 2D array works?
 
@Mat'sMug Writing code with spreadsheets should only be for repetitive SQL queries... lol
 
I mean, code like this is exactly why the "code as if it will be maintained by an axe murderer" argument was made for
 
They probably don't teach that argument in 10th grade.
 
and shouldn't the commas be semicolons?
they probably don't teach braces either then
 
8:51 PM
No.
This is allowed.
It's one of the ugliest things I've seen in a while, but it's allowed.
It's possible to write ugly code in all languages, even in C++.
 
I know it's legal, but if I were a teacher and had to review such code... I'd be blind by now
 
1
Q: How would you do this with lodash/underscore?

NietzscheProgrammerI have a .json which looks like this but it is actually way much bigger [ { "enterprise" : [ { "id" : "743512", "name" : "Hellen Quesada", "role" : "P. Software Engineer", "picture" : "http://i276.photobucket.com/albums/kk35/Sicable/200x200/06.png", ...

0
Q: How filter a grid from a tree list

Juan Carlos OropezaThe Tree has a list of car ids, group by how old was the last update. User can select a group or just a few cars to watch on the detail grid. Im using Jquery Ajax to call my WebApi. With Recent and Old(42) I get the right result, but with New frozen and didnt return a result. I guess there are ...

 
Good code is like straight teeth: it needs braces. — Mat's Mug 5 secs ago
 
@Mat'sMug #DadJoke right there
 
oops, I did it again
 
8:55 PM
Is it at least the Children of Bodom version?
 
51 secs ago, by Mat's Mug
oops, I did it again
^^ I think that's B.Spears....
 
yea, but IIRC Children also have one...
 
wut
 
♪ oh baybah baybah ♪
lol
 
8:58 PM
@Malachi wait, I actually clicked post answer? I don't even remember that.
 
FWIW I deleted the comment
 
Questions like this are on-topic at Code Review, but not here. — Jim Garrison 25 secs ago
 
9:16 PM
I clicked on Contacts in Outlook because I needed to look up someone's phone number, since then Outlook has been lagging a solid 15-20 seconds behind
 
9:31 PM
well it's finally TTQW
 
0
Q: Basic vector based drawing OOP design

WissemI had an exercice as below for an interview. I've added my implementation at the end. How could I improve it? Develop a simple vector based drawing package. Your application should support the following 5 drawing primitives (we will call them widget) 1) rectangle 2) square 3) ellipse 4) circl...

 
I had a code review comment where someone had used — Michael Mathews 18 secs ago
I had a code review comment where someone had used if (container.insert(foo).second == true) { //do something as this is the first time we've seen foo } I changed it to <code> if (container.find(foo) == container.end) { //do something as this is the first time we've seen foo container.insert(foo); } </code> – — Michael Mathews 20 secs ago
 
0
Q: mySQL Union or What?

sgkdnayHere is what I have in mySQL: SELECT ASEnemy,ASFlagStatus,COUNT(SCAlliance) Server,0 State FROM AllianceStatus INNER JOIN SC75 ON (SCAlliance = ASEnemy AND SCSnap = (SELECT MAX(DSSnap) FROM DataSnap WHERE DSServer = 75)) WHERE ASServer = 75 AND ASOurs = '1057' AND (((SCFi...

 
10:05 PM
0
Q: Simple python console websocket client and tornado websocket server

Yevhenhttps://github.com/yevhen-m/async-chat Hey guys, who has a minute or two to review my exercise python project on websockets? I would be very grateful for that.

 
Unfortunately, you must include the code in your question for it to be reviewed. As it stands, your question is off-topic, however, once you include code, we'd love to review it! — Quill 12 secs ago
Unfortunately, broken code is off-topic on Code Review. Once you have code that works and does what you want, we'd love to help you do it better. — Quill 8 secs ago
 
10:33 PM
@PinCrash what's 20 seconds when Outlook spends an hour a day not responding anyway? ;-)
 
0
Q: Cyther: The Cross Platform Cython/Python Compiler

nickpandolfiI wrote a module that acts as a script, and will automatically compile a Python or Cython file without the user having to do anything other than: C:\Project_dir\> cyther example.pyx or C:\Project_dir\> cyther example.py ...as long as gcc is accessible from the system path and cython is inst...

 
@Mat'sMug what's 20 seconds when you spend three hours manually deleting emails from db_test_mail anyway?
 
^^
 
0
Q: Circular Buffer

LastSecondsToLiveFor my current project I need a circular buffer, which is able to do the following things: Push something to it (to the head). Pop something from it (from the tail). I don't need the popped data. Peak the head and tail (no popping). Iterate through the currently contained elements. Here is my...

 
10:49 PM
hi all, my question has been up for just under 2 weeks with no reviews - I don't want to ask for a review, but just wonder if there is anything glaring that I should reconsider for future questions?

http://codereview.stackexchange.com/questions/121916/simple-dictionary-storing-viewing-application
 
You haven't done anything wrong :)
Reviewing code is a long process sometimes
2 weeks sounds like a while, though
 
thanks Quill - based on what I've seen on some other questions, it did seem like a fair amount of time so I was wondering if there was something that made my question particularly undesirable
 
did you just bounty ninja me @JeroenVannevel?
 
and me too
We've been Vannevelled
4
 
So, @Tony, @JeroenVannevel has just added a bounty to your question, which should help draw some more attention to your question
hopefully get you some good looking answers :)
 
10:59 PM
LOTS OF TALK AFTER THE FACTS, PEOPLE
 
0
Q: Should a method include related functionality not described by its name?

SouvlakiSuppose a class like this: public class MapController { Polyline _currentPolyline; // The line connecting two locations on the map Googlemap _map; public void drawRoute() { clearRoute(); // One route can be shown max at a time /* Some code preparing the path to ...

 
Unfortunately, hypothetical code is off-topic on Code Review. — Quill 15 secs ago
 
oh wow, thanks @JeroenVannevel, very much appreciated
 
Bountied C# zombies are always fun to answer
 
@JeroenVannevel when are you going to hurry up and reach 10k?
 
11:03 PM
^^
When he stops ninja-bountying zombies
 
lol
 
oh hey, I'm learning for my programming fundamentals class, so I might be posting some of that soon. Big change from the flexible jelly JavaScript I'm used to
it's pretty cool so far. though most languages are cool in their own way
 
@Mat'sMug, i liked your solution to codereview.stackexchange.com/questions/122933/… much more than mine, but I was wondering would it have been better to construct the TRowItem in the loop and pass that to IsNonEssentialRow?
 
Oh you're @worker!! ding ding ding
 
yeah, I just merged my accounts - apologies I should have cleared that up
 
11:08 PM
Meh, I changed names a few times myself :-)
@Tony possibly, but TBH I'd use a class module instead of a UDT. VBA has weird scoping rules for UDT's
 
it's a cool feature that stackexchange has, that's for sure
 
Well, it's actual code, but I skipped some lines. If I add them would it be ok? — Souvlaki 59 secs ago
 
gtg, bbl
 
Potentially, yes, but we'd need to see them before we can determine that. (and please tell us what language this is in too) — Quill 18 secs ago
@Mat'sMug see you later
 
@Mat'sMug later
 
11:10 PM
Ok, edit incoming in a few minutes. Thank you! — Souvlaki 15 secs ago
Added concrete code. — Souvlaki 1 min ago
Okay this is good to reopen
1
A: Smoke the SmokeDetector

SirPythonI'm sorry, but my review is going to be short; your code looks pretty good. Refactor node deletion You did a very good job of refactoring your code for the most part. The only repetition that I can find is here: var parentNode = message.parentNode; parentNode.removeChild(message); if (paren...

Good stuff @SirPython :D
 
Thanks ;)
 
11:45 PM
I wonder if they noticed this:
user image
5
 
that's usually how fax numbers are, aren't they? really close to the phone number?
 
Do you get it?
I included the website for a reason.
 
Hah, I see it now.
 
BTW, @Tony, your code looks pretty good.
 
Lol. Whiskey Tango Foxtrot
 
11:55 PM
oh. how did I miss that
 
@Quill Oh boy! Let's do some bit twiddling! Pop quiz, how do you clear out the left four bits of 11011011?
 
no idea.
 
Left shift 4, right shift 4?
Or use a bit mask.
 
0
Q: Changing a variable using an if statement

Shadow7So I'm trying to change a variable using an if statement I almost know that it's possible, but I'm not quite sure how to get it I am trying to do it where it's a 1 and then when it reaches a certain point it will be multiplied by a negative and it changes to a negative 1 changing the direction an...

 
@Hosch250 Bingo. And it with a bit mask.
 
11:57 PM
Unfortunately, here on Code Review, we require the code to be included in the question for us to review it. As it stands, your question is off-topic. Once you include some working, non-hypothetical code, we'd love to help you do it better. — Quill 9 secs ago
 
OK, so at least I know what I need to search to do it.
I don't know how to do it off hand, though...
 
can we get some reopen votes on this, please?
0
Q: Should a method include related functionality not described by its name?

SouvlakiI have this class: public class MapController { Polyline _currentPolyline; // The line connecting two locations on the map Googlemap _map; public MapController(GoogleMap map) { _map = map; } /** * Draws a route on the map. * * @param directions th...

 
Eh, you should ever really need to know how these days, but it's cool.
 

« first day (1048 days earlier)      last day (2974 days later) »