« first day (983 days earlier)      last day (3035 days later) » 

10:00 AM
0
Q: Too many database queries downgrade performance

tribetThe following code snippet is causing me a performance problem in my application. The first 5 db queries are not high time consuming, the real problem lays on the foreach loop. I considered to use Dictionary structures instead of List to improve the lookups, but improving the loop will make the r...

0
Q: Somewhat less semi-primitive IRC bot serving as learning project

SemiViralI am back again! With version 3.5! As of now, instead of the previous 4 or 5 out of 10 (relative to my C# programming skill), I'd say I'm a solid 6, and some of that is thanks to the advice I got from the last revision. Here is the code: Eve.cs, primary file User class public class User { ...

 
@DanPantry he did the trouble to change it to length 8 chars and removed the lowercase ;)
 
@chillworld true but IMO it is still too similar to not be a plagiarism
Everything else is exactly the same, right down to the == (which you shouldn't use).
 
How is this a long term impact question? It seems short term if anything — Quill 6 secs ago
@StackExchange that's crap
in JavaScript on Stack Overflow Chat, 5 mins ago, by Maurize
@DanPantry you idiot. It is copied and I've added reference because this. http://stackoverflow.com/a/33425737/3119231
 
@DanPantry you are 100% correct; he should mention it as a reference also
typical SO attitude pffffft, That's why I love this chat so much
 
0
A: Long term impact of not editing/deleting questions that's led to revised code

QuillStack Overflow's Question and Answer structure you're talking about works like this: There's a bug in your code, and you have a snippet to support / show that. You receive an answer (a fix) and you subsequently edit your question to show the fix. But the bug is still there, you're not asking a...

bbl dinner
 
10:08 AM
@Quill Meh, and yet you still didn't obey the helpdesk when it comes to referencing. But go ahead and call me an idiot, I just wont' go back to that SO room
 
@Quill If you think it's a duplicate you shouldn't really be adding an answer
And monking all!
 
Monking @SuperBiasedMan
 
@DanPantry I'm just looking in the link he provided. The code of your site is in that site also
 
@chillworld Yes, I noticed
 
so actually he did correct
 
10:20 AM
I noticed after emotions died down that the person he cited had cited the original source that I found
Unfortunately I can't retract flags
Though I disagree with an answer consisting only of externally sourced code (and not the author's own).. that's a meta discussion, not something to be decided in downvotes and flags
 
It's a bad answer all round, but I at least edited it to change a vague reference to explicitly saying "I got this code from [here]"
 
i really dislike the "we don't usually help help vampires, but you're new here"...
In the 3 interactions I've had with that author, he has acted condescending
 
Sometimes people don't see the value in politeness/respect, especially online.
It's easier to ignore the consequences online.
 
@DanPantry a guy with 300 rep doesn't need to say that
 
10:26 AM
that is what I mean with SO attitude, everyone thinks they are the new John skeet and know as much as he does
while here, @rolfl, a great reviewer who has a deep knowledge even listen to me, a junior developer who needs to learn a lot, and check if it could be correct what I'm trying to point out
 
@DanPantry thanks for the edit :-)
@chillworld the attitude here is that you can and are always learning
 
@Quill indeed, and I did learned a lot from CR, even more then from SO
 
I have 2nd monitor open in two chrome windows.
That explains why I kept hearing double
 
@DanPantry CR in stereo ;)
 
Zak
10:59 AM
SO is very much "Give a person a fish, and perhaps detailed instructions on the nature of fish and how to cook it", whereas CR is very much "Teach a person how to fish".
 
@Zak Or why you should not use a fish but instead drop that and use jQuery instead
4
 
possible answer invalidation by Thomas Schremser on question by Thomas Schremser: codereview.stackexchange.com/posts/82468/revisions
 
@DanPantry "Why are you using a fish for this casserole? jQuery would be much better."
 
I'm trying to find a gif of beating a dead horse, but all I can find are photobucket which disallow hot links. :\
Never mind.
 
Zak
@Duga Is fine, just a comment style tip someone mentioned in the comments.
 
11:08 AM
@SimonForsberg are you planning on writing an answer to that meta question?
 
I know they don't, a lot of the coding standards that we use for Java code are based around C conventions, you're preaching to the choir on the correctness of the standards, I'm just looking for something that will ease some of my hassle when it comes time for code reviewing. — Kialandei 17 secs ago
 
@Duga I feel for this man
Coding standards that aren't updated to suit the times do more harm than good
 
Hmm. I think I was serial downvoted on a site where I'm barely active.
All three of my posts were downvoted in the space of two minutes. Is there any point in flagging for a mod?
 
also @SimonForsberg can you quote the don't edit the solution into the question on SO source please? being honestly curious here
 
I don't have a source but it's definitely the case, yeah.
It's much better to be able to see the original problem and then separately see the answer/s, rather than muddying the original problem with a solution.
 
11:14 AM
Whether it's good or not is a separate thing to whether it's okay
 
Well it's explicitly not ok, I'm sure I've seen as such on meta before.
 
Yeah, if you could just link that, that'd be great
 
0
Q: Jacobi method to solve Ax=b

AbolfazlI am working on solving linear system of equations. For the first step I'm going to solve a general 3x3 matrix with Jacobi method. Everything seems to be correct except the answer. Here is my code: program main implicit none integer :: i,j,it, it_max integer ,parameter :: n = 3 real(8) :: r_max,...

 
> Everything seems to be correct except the answer. ... Do you have any idea?
 
So close..
I just altered a file only to change the indentation from 4 spaces to 2 spaces (so ti actually fits in a single window).
The thing this file displays is a menu.
 
11:20 AM
I'm afraid this question does not match what this site is about. Code Review is about improving existing, working code. Code Review is not the site to ask for help in fixing or changing what your code does. Once the code does what you want, we would love to help you do the same thing in a cleaner way! Please see our help center for more information. — Quill 20 secs ago
 
Before altering the indentation, the menu would float left of my cursor.
now, it floats right.
 
What kind of file?
 
.html.
 
@CaptainObvious RBA
I misread the meta question and answered to how I read it, incorrectly, as thus, my mistake recognised and post deleted.
 
Monking all
 
11:29 AM
This is not codereview.stackexchange.com but your code is too complicated. — lhf 6 secs ago
 
@Zak Not necessarily, it's more teaching someone what's wrong with his current fish so he can catch a better one next time.
3
 
awesome, now it's completely resolved
 
Monking
Note to self: Write less notes and do more
2
 
11:37 AM
Notes are good.
Ovethink your notes, then implement when you've reached design agreement with yourself.
 
@Morwenn That would be never
 
@skiwi Even for a programming projct?
 
Possibly... so at some point I just go for it
Hmm the swag form asks for State, now over here we only have the notion of Province, I guess I should use that then?
 
Yeah, I used to have the nike philosophy, then I realized that it's a perpetual one. I prefer the monky philosophy.
 
@skiwi ping JNat if you're unsure
 
Zak
11:39 AM
@rolfl And pray tell, what is the monkey philosophy?
 
Why "Just do it!", when you can "Just did it!".
 
When I have a design issue, I simply open an issue on the project and throw all the ideas in and edit it whenever I have more things to say about it. Then when I think it's ok, I start implementing it.
 
Zak
My current project, I got most of the way through it, and after re-factoring/re-designing it several times, I got frustrated and just blitzed the last 100m with not-great-but-serviceable code instead.
 
I start coding with less than half the design in place. I often find that the code goes in a direction that makes the original design ideas less than practical.
 
11:42 AM
I thought that was the monkey philosophy
 
I opened an issue on a project the 23rd of September and only closed it the 5th of January. The issue was simple and the design decision too but it took me that to balance the pros and the cons. Then a day to actually implement it while meeting new problems on the fly.
 
Zak
@skiwi s/less/fewer
 
@skiwi Monkeys have many philosophies - including "chose the philosophy most amenable to the conditions"
 
monking @rolfl
 
monking ;-0
 
11:43 AM
Everytime I change how something works I need to update the documentation, so I prefer no rushing things x)
 
@Morwenn Ah... you have that thing
 
if(code == broken){ fling(code); }
 
@skiwi Yeah, and a test suite too. And tutorials.
 
I think that's because you code in systems that have documentation.
 
And examples.
 
11:44 AM
I have the "luxury" of building something completely from scratch. It changes the game somewhat.
 
if (code.status == Status.BROKEN) {
    code.fix();
}
if (code.fix.status == Status.BROKEN) {
    code.user.planet.nuke();
}
Hmm, a tag line for CR of the following would be a bit evil, wouldn't it?
> Now you have two problems to choose from
 
why is fix both a property and a method
 
@rolfl I'm currently in the same boat
@Quill is "because Javascript" an acceptable answer? (even though this isn't Javascript)
 
Building from scratch means you keep re-designing because you learn new things along the way. Your first design will be obsolete quite quickly, as will the 2nd, 3rd and 4th version.
 
@DanPantry But your boat is written in JavaScript, so it will sink anyway ;-)
3
runs
 
11:49 AM
@skiwi It won't sink.. it'll just run into an iceberg. Titanicscript.
 
@DanPantry You would use .then instead of a second if statement
 
@Quill Only if it were asynchronous & promise based :D
 
Here be pedants
6
 
@DanPantry either way, you can't assign fix to be a property and a function in JavaScript
 
@Quill yes you caaaaaaaaaaan
function fix() {}
fix.status = Status.BROKEN;
const code = { fix };

code.fix()
code.fix.status
 
11:55 AM
@rolfl Oh, I was also talking about a personal project that I built from scratch.
Ergh, GitHub blocked my profile because one of its bots thinks I am not human.
 
@Morwenn you are? ;-)
I joke. That sucks, though
 
0
Q: Why Deleting a Range is Quicker than Deleting individual Rows

Jean-Pierre OosthuizenI have a script which i use to delete rows from a Excel Sheet, this is dependant on the Column C cell of that row being blank. I am busy trying to shorten/optimize my code and found another solution which requires 7 line of code verse my original 17 lines. However the Shorter Code takes less th...

 
@DanPantry I think I pass as one.
 
So we have a robot and a monkey.. this almost constitutes a Doctor Who episode
3
 
And I was about to showcase one of my awesome issues :(
 
11:59 AM
@DanPantry how did I forget this... *looks away*
 
Zak
@CaptainObvious This belongs on SO
 
Maybe a better question for codereview? — Pikoh 36 secs ago
This may get a better response in codereview.stackexchange.com - I would mention though, instead of concatenating strings together to form a path, there is the Path.Combine() static method just for this purpose. — gmiley 56 secs ago
 
@Zak Absolutely sure?
 
Zak
It was when I linked it. Since edited.
 
12:08 PM
It's definitely not a good CR question, but I'm not fond of migration proposals.
I'm even tempted to flag the answer as NAA, since it's not a review.
 
Monking!
 
Can anyone see this or not?
 
I love how you moved a quote of a message that you moved
 
@Morwenn I can see it
 
@Morwenn Yup.
 
12:10 PM
@chillworld Ok, cool, it means that I'm human again :)
 
@Morwenn Yes
 
@Morwenn to much coding on github so they think you are a bot?
 
Zak
@Mast Right now, it's an *OK* question, but I'm going to give the OP some pointers on improving it. The selfie, though, is another matter.
 
@chillworld I don't know why the bot considered me a bot. Maybe the bot was in love with me. I must have deceived the poor thing.
3
 
got to go, new years drink here at work
 
12:12 PM
:D
 
@Morwenn well, maybe that's a good thing when the AI take over the humans;)
 
@Quill Redundancy department eh :)
 
see you later all
 
@Phrancis Cleanup crew more like
 
@chillworld Few days late, but... Enjoy!
 
12:14 PM
@chillworld Have fun :)
 
5
A: BigBrother - A chat room watcher

janosBug(s?) in createTaskPool This function makes a reference to lastMessageIndex, but I cannot find that anywhere in the code. Perhaps it was meant to be lastTaskIndex instead? function createTaskPool() { return setInterval(function() { if(tasks.length > 0) { // dequeue the me...

Congrats @janos on the bounty and thanks for the good answer :-)
 
@Quill I wouldn't call it that. A nonconformist opinion, and perhaps even misguided, but it's a fair question.
 
@Quill with the default zoom level of firefox this looks like -100 rep
 
lol
 
@Heslacher Lol yes, you are right
 
12:23 PM
@Heslacher I agree.... post a meta-bug.... get a hat. Oh.....
 
;-)
 
 
@skiwi Heh, there it looks more like "divide" ÷
Reputation / 100 ;-)
 
So that's 0.07 rep for that answer?
 
@rolfl Same here. Very ugly.
 
12:32 PM
This needs another approval (yes, it's a good edit): codereview.stackexchange.com/review/suggested-edits/50579
 
1
Q: Configurable products price class

RobbertIntroduction: I have a website where customers can configure and checkout glass products like for example: Shower doors, Mirrors, Kitchen splashbacks, Table tops etc. What I am trying to do: I am trying to create a class for calculating the price of this kind of configurable products. All the ...

 
@CaptainObvious ,
 
Greetings, Programs.
 
Mr. McLean! Greetings.
 
@Mast the page you gave me has a point which says "or provide a viable alternative" so now what — Jean-Pierre Oosthuizen 8 mins ago
I ran out of ideas, can anyone tell that guy it's not an answer?
 
12:40 PM
1
A: "3 questions" in Stack Overflow comments pointing to Code Review

200_successIf we're going to be posting these kinds of comments, we should be careful not to steal questions from Stack Overflow that are actually on-topic for Stack Overflow. (That's important: many Stack Overflow users (both newbies and veterans) don't understand what makes a question inappropriate for S...

 
@Quill At this time I cannot quote it, but I would say it is "common sense of a Q&A site", and I've seen @Vogel612 edit some questions on SO that writes something like "UPDATE: The fix was to do XYZ"
 
@Quill ^^ for your interest
(and everyone else of course)
 
@SimonForsberg it was quoted above by SuperBiasedMan
do you want to add it to the examples in gist, @Phrancis
 
good, thanks @SuperBiasedMan
BTW.Work
 
@Quill Maybe? I don't know
 
12:42 PM
alright no worries
 
@SimonForsberg I got the feeling I missed something :/
But yea I usually make a CW answer from these, if it wasn't from an already existing answer
 
ttgtw
 
0
Q: Web app to consume rest services and display charts accordingly

codeomnitrixI have been an angular developer for more than 5-6 months and mostly I learnt with my experience. However recently after submitting a code to some competition I got a feedback that angularjs best practices not followed. So I think I need some help understanding about irregularities in my code. ...

 
1:00 PM
@CaptainObvious Server-consuming client, nomnomnomnom.
 
@Mast lol
 
 
@skiwi There was no code to analyze, therefor NullPointer?
 
There definitely was code
Just some IntelliJ bug
 
was. past tense. it's all gone now.
no more code. RIP.
 
1:03 PM
Jean-Pierre just entered the CR Help Desk, for those interested.
 
@CaptainObvious I'm concerned about the:
> Rest of the code I have shared on google drive with link - drive.google.com/folderview?
 
@DanPantry Code-consuming analyzer.
 
@Quill I saw that too. So I ignored it
 
@Quill Same here, I'm not touching that question.
 
@Mast nomnomnomnom.
 
1:04 PM
^^
 
Wow, someone using the Help Desk in a helpful manner
 
@DanPantry why not?
 
@nhgrif Too many
you write too much. ;-)
Seriously, though, all of your articles are great
 
Some would argue not enough.
 
His most recent has been a while though.
Wasn't 10 commandments the latest?
 
1:06 PM
Like @Phrancis who has rightfully pointed out that I'm overdue for one.
 
Yeah, he's right too
Oh hey, @DanPantry I think I found one of your sites you've designed: lingscars.com
 
@Quill holy shit do not go on that it locks up your pc
 
it's just a bad design man
 
Also, no, I'm bad at design, but not that bad
No, it literally locked up my chrome due to all of the animations lol
 
I was just kidding, but seriously, CSS is hard for those with no design talent though
 
1:10 PM
CSS is easy, it's just another programming language
Making things look nice is hard
I mean, you can get a degree just in UX.
 
Missing In Action: Free Drive Space on the C drive
4
 
You don't need a degree in UX to see that site is a bad idea.
 
@Mast Of course not
 
Meanwhile it found 8,77GB with disk cleanup
 
But you (more often than not) need a degree/equivalent exp to determine how to make a good site.
 
1:11 PM
Did anyone see YouTube broke last night? For like half an hour or so
 
Anyone can see that the buildings outside my office look crap, but not everyone is a structural engineer and can build replacements.
@nhgrif wat
 
@Mast I have a feeling where all my space went...
That's my Recycle Bin
 
@skiwi starring Tom Cruise?
 
Next time use shift+del :P
 
It's "Garbage can", not "Garbage cannot". Get rid of that stuff ;-)
 
@skiwi That's not how you VCS ^^
 
@DanPantry lol
Still 50GB for a .war file seems like an awful lot
 
potentially nsfw: arngren.net
 
0
Q: Custom Implementation of ObservableDictionary

psubsee2003I recently found myself in need of an IDictionary<TKey,TValue> implementation that was observable from a WPF UI. Since the .Net framework does not provide one, I rolled my own, but borrowed very heavily from what ObservableCollection does on its own. And since there is not generic implementatio...

 
Anyone here uses WebStorm?
 
I question the value of links to crap car lease websites in this chat :p
 
If you want to get working code reviewed, better ask at SE Code Review. — πάντα ῥεῖ 14 secs ago
 
@DanPantry It's one of those sites designed intentionally crappy
 
> As seen on the BBC DRAGONS DEN
 
> but are there any potential problems with this approach? In particular, is the fact that I am changing x0 that is referenced by the const vector x 'legal' C++, or is it something that other compilers might complain about? Also, can I be sure that the first constructor avoids copying data?
that seems awfully not like "review my code"
 
1:23 PM
This may be a good question for Code Review, so long as: (A) the code works, and (B) it's not hypothetical or incomplete in any way. Please read the on-topic guide before posting, if you choose to go to Code Review. If you have any questions or concerns, join us at our CR Help Desk. — Quill 33 secs ago
 
@Quill It shouldn't go here.
 
@Mast +1
OP doesn't seem to understand their own code
 
I'm still going to post the link
It's not a this is a good question, it's a this may be a good question
 
Every question is this may be a good question if it wasn't crap
But, let the community decide when it gets here
If it gets here
 
Don't migrate crap.
 
1:26 PM
"If in doubt, don't"
 
-1
A: Deleting rows from a spreadsheet where Column C is blank

Jean-Pierre OosthuizenThe code below uses 7 lines verse 17. It deletes the Rows individually as opposed to deleting a Range of blanks cells. Unfortunately, it does take a little longer than the original code as posted in the question. So, it will only be better in terms of reducing code length. Sub Longer() '140ms ...

this just got edited, thoughts?
 
@Quill OP prefers LoC over performance, I think that says enough.
Somebody should OP to get his priorities straight.
 
If you want to talk to him, he's in help desk as you pointed out
 
I think OP needs something more constructive than what I just said.
 
@SimonForsberg my bad, made a typo. Corrected it. Thanks for pointing it out
 
1:32 PM
@Phrancis and @Morwenn thx, it's already over for me :)
 
@DanPantry no problem. cleaned up some comments there as the answer has been improved.
BTW.Work
 
I'm voting to close this question as off-topic because it seems like a better candidate for codereview.stackexchange.com. — deceze 35 secs ago
 
@chillworld How was it? :p
 
pfffft a speech in Dutch and French, luckily a very good friend was there to chat
 
@deceze That's not a valid close reason. This has been pointed out often enough before. It's too broad here and may be a good candidate for Code Review. — Mast just now
 
1:41 PM
0
Q: Javascript BB-Code transformation

MarvI am doing a lot of stuff with Javascript and jQuery lately, but am not heading for clean code too much, as I am usually writing userscripts or small applications for myself. Recently, a community I am part of announced that it will change their supported BB-Codes, as the tabmenu BB-Code had a p...

0
Q: How do I choose the desired icon when fetching results?

AlexI'm creating a Q&A website, Something like SO. Now I need to print a "check" icon (to specify accepted answer) next to every answer. Now there is some condition: Current user is logged? Current user is author of the question? Is there any accepted answer? And some other cases ..! Actually ...

 
I like the way I improved at Java by not using Java and switching fully over to web development..
 
@DanPantry not sure how Future<bool> is valid java, but eh
 
@Vogel612 what do you mean?
 
Probably something from the future
 
@DanPantry for one, the primitive type is called boolean... aside from that you cannot use primitives with generics (yet)
 
1:45 PM
Would there be a better stack exchange forum to post this in, such as code review? — Ben Sewards 10 secs ago
 
@Vogel612 are you sure about that? the code I wrote there was definitely running
I agree on bool, though, that should have been boolean
bear in mind those signatures are just descriptionsr ather than actually from the code excerpt
 
@Vogel612 public class bool { } cringes
 
AT the time I probably got bool and boolean mixed up
 
monkeyt ypos
 
@skiwi I was bad. I was not that bad.
I was working for a .NET company @ the time, and in C#, it's bool
 
1:46 PM
@Phrancis Monkey stealing keys from keyboard
 
Monkeys only steal the space bar until one character later
 
I like to think I've improved a lot in the past 18 months, though :-)
.....oh lord, it's been 18 months..
 
@BenSewards given that your code seems to work as intended and in this form is "complete" I'd say that this would be on-topic at Code Review. Before asking I'd recommend reading the extended asking help for Code ReviewVogel612 37 secs ago
 
@Duga I was just about to comment that. It could be a good CR question, but it could use some clarification before it gets here.
 
1:59 PM
0
Q: jQuery custom slider optimization

ccdaviesThe following code is a custom slideshow viewer. Its working correctly, but I am wondering if anyone can see any way of optimizing it, or making it more efficient. I am using Transmit for CSS3 transitions (http://ricostacruz.com/jquery.transit/). $(document).ready(function(){ var $slidesho...

 

« first day (983 days earlier)      last day (3035 days later) »