5,277 reputation
944
bio website
location
age
visits member for 2 years, 8 months
seen 8 hours ago

Dec
17
comment How does Yahoo's Smush.It work and why doesn't everyone use it?
It's pretty trivial to get close to 100% compression on a smooth white image.
Dec
9
comment Stop re-iterating over duplicates in nested for loop
I would also do "i < particles.length - 1" that way you won't go over your length.
Dec
5
comment Why does not thinking about a bug sometimes help you solve it?
I vote for reopening this question, because problem solving in the programming field, and why you get stuck is something very particular for this field.
Dec
1
comment Advantages of unmanaged code
When starting a discussion like this you should be specific. The way you state : "You do not have to worry about explicitly garbage collecting." As an advantage the unmanaged code does not have, while unmanaged code is actualy all other languages, which have and don't have GC so the advantage is over what?
Dec
1
comment Advantages of unmanaged code
The term "managed code" is microsoft specific.
Nov
25
comment Merge sort versus quick sort performance
If your strings are an average of 4.5 characters long. Then on a dataset with 10,000,000 strings there will be a lot of duplicate strings. Try using random strings with an average of at least 8 (or preferable more) characters.
Nov
14
comment Sorting displayed results vs. entire results
This question belongs on ux.stackexchange.com
Nov
9
comment Is it imaginable to teach a machine how to program itself to a defined specification?
Define programming. I could build a program that would makes other programs. But would it really learn?
Oct
23
comment Code that converts a value into a different representation, then converts it back to where it started is bad, but how?
@CodesInChaos yup, that's why I want my code to be locale agnostic and only when showing output to a screen will I apply it. But I think that's another discussion because you could write books on that subject.
Oct
23
comment Code that converts a value into a different representation, then converts it back to where it started is bad, but how?
@DanielRHicks so let's convert that simple date(10 november 2014) to a string, ->10-11-2014 and back to a date ->(11 oktober 2014) hey wait what?
Oct
22
comment Why are floating point numbers used often in Science/Engineering?
@slebetman Besides that it has nothing to do with my point in my post, if math is a science or not I can't help to drop a quote : Nature is innately mathematical, and she speaks to us in mathematics. We only have to listen. Because nature is mathematical, any science that intends to describe nature is completely dependent on mathematics. It is impossible to overemphasize this point, and it is why Carl Friedrich Gauss called mathematics "the queen of the sciences."
Oct
22
comment Why are floating point numbers used often in Science/Engineering?
@leftaroundabout what do you mean math (as in mathematics) isn't science? In my book it is.
Oct
15
comment SQLDatabase: Read a lot of data at once and process in memory or read the data when I need it?
@Recipe also make sure to really pull large numers of records at the same time and not go through a resultset where you're basically still pulling 1 line at the time with all of the overhead that goes with it. Look into things like rowsetsize .
Oct
15
comment SQLDatabase: Read a lot of data at once and process in memory or read the data when I need it?
My solution to this was a hybrid: instead of pulling 100.000 lines from the databases at the same time or pulling 1 line a lot of times I pull blocks of 1000 lines at once which gave the best improvement. Beware though, any solution is extremely dependant on what situation you're in.
Oct
15
comment Overwriting and returning the value of the argument used as conditional of an if statement, inside the same if statement
Are there cases when it really matters? : Yes....you logger will log: "the color is blue" even if the color is green.
Oct
10
comment When does one hard-code actual data values into the code as opposed to using a DB?
The untold consensus has typically NOT been as such: If it is a single variable or a simple structure, or an array of a few values, put data right in the code.
Oct
10
comment How can I rank teams based off of head to head wins/losses
You're missing a time component. (In sports at least) a recent win is often much more significant then a win in the past.
Oct
10
comment Static and not-static: programmer quantum theory
To me the thing you want to do just feels dirty. If having a static method fits your use case, lift it out of the class and use it in a seperate class with static methods and remove it from your original class.
Oct
7
comment How to compare two different hashset objects with more than 100,000 records
by comparing each value in set A with each value in set B you get 100.000 * 100.000 comparisons. Which is a lot. Advise to do a sort on both lists and only search forward.
Oct
6
comment What are classes that produce a result, but are necessarily classes because of the complexity of the task?
Do you mean black box?