2 ms·
You can use bad hashing functions for a lot of applications. In the traditional interview question: find all anagrams in a list of words, you can sort the lette
by matthewaveryusa 8y ago
You can use bad hashing functions for a lot of applications. In the traditional interview question: find all anagrams in a list of words, you can sort the letters of a word as the hashing function, and use a traditional hashmap that does conflict-resolution with a linked list as a solution. Fun stuff
- jimktrains2 8y agoBad isn't the right word here. It's a bad cryptographic hash, sure, but a hash doesn't necessarily need to be cryptographic to be a hash. P-hash for finding similar images; sounded/metaphone for similar English pronunciation; crcs, cityhash, siphash, &c for fast checksums and hashtables; and location sensitive hashes like simhash for "close matches" for spam filtering and content aggregation all have a long history of being good and useful hashes without being cryptographically secure.