News for hackers. Stuff that matters.
Re:Speed Hashing by marcusf on Friday April 06, 2012 @07:35AM (#3806725)
Not to pile on with the nitpicking, but for just the cases everybody here is talking about (eg non-crypto hashing) you get to "pick" exactly the hash function. You're forced, actually, to implement hashCode() in Java if you want to be able to put the object in a HashMap, HashSet, etc.
Re:Speed Hashing by canop_fr on Friday April 06, 2012 @07:42AM (#3806747)
You're right but that's still in a very small subset of possible hashing functions because you must produce a 4 bytes hash, which is then hashed again (to the length of the storage array). Of course you don't have as requirement to avoid collision, just to distribute as equally as possible.