Reputation
2,739
Top tag
Next privilege 3,000 Rep.
Cast close & reopen votes
Badges
2 8 19
Newest
 Enthusiast
Impact
~83k people reached

Jul
30
comment What if the “catch” block is empty - “{}”
@Wilman If you rethrow using throw ex; instead of throw; you overwrite the stacktrace.
Jul
30
comment Difference between == and .equals (java)
Reference vs value equality.
Jul
29
revised How to promote code review as an employee?
added 24 characters in body
Jul
28
comment Is throwing new RuntimeExceptions in unreachable code a bad style?
@MatthewRead The execution of code intended to be unreachable is a severe bug, return null is quite likely to mask the bug because you can't distinguish the other cases where it returns null from this bug.
Jul
23
reviewed Approve i++ vs i+=1 in cycles, why evaluate?
Jul
22
comment File sharing web application - folder PIN code entry best practice
Why PINs instead of some kind of ACL? Password sharing isn't exactly good practice.
Jul
21
comment Is an interface considered 'empty' if it inherits from other interfaces?
Being unable to specify several interfaces as type of a parameter/field etc. is a design flaw in C# / .NET.
Jul
18
comment What is the time complexity of the algorithm to check if a number is prime?
In practice we use probabilistic algorithms with runtime O((log n)^3) (or slightly lower if you use fancy multiplication algorithms) instead of AKS.
Jul
13
comment How to sort fractions (small numbers)
You forgot to subtract the q from the exponent.
Jul
13
comment Is there a name for this pattern?
I know that a few APIs following this pattern exist in C#, but usually foreach together with an enumerable is the cleaner choice. It's certainly rare enough to not count as a C# idiom.
Jul
13
comment Is there a name for this pattern?
I think this code is idiomatic in C, but in C# I'd rather use an enumerator instead of a function that either returns a value or a special terminator.
Jul
11
comment long (or bizarre) file paths
Mostly hits my media collections. If you include artist, album and song name you can get names that are pretty long. Add a few directories on top of that and you can easily hit 260. I don't think I've hit 512 yet.
Jul
11
comment long (or bizarre) file paths
Most windows APIs have a 260 char limit and it's annoying as hell.
Jul
6
reviewed Approve Is overriding Object.finalize() really bad?
Jul
5
comment What is the “default” software license?
-1 for "implicit statement that it's OpenSource". Just because people may view your code doesn't mean it's open source.
Jul
1
answered Recommended HTTP status code for “plan limit exceeded” response
Jul
1
comment Recommended HTTP status code for “plan limit exceeded” response
RFC4331 might be relevant, it's about quota limits for WebDAV.
Jul
1
comment Recommended HTTP status code for “plan limit exceeded” response
There is HTTP 507 Insufficient Storage.
Jun
29
comment How to store passwords which need to be re-read
"and a 'random' number" what do you mean by that? Usually the salt is the random number.
Jun
29
comment How to store passwords which need to be re-read
Encrypting the password is slightly better than storing it in plain, but not much, since you still need to store the key somewhere.