http://qs1969.pair.com?node_id=488802


in reply to “A meeting at the Liquor-Vodka Factory”, or… same ARRAY questions again?!!

* Using a hash is a pretty smart solution, except:
- It has memory implication (hence not always can be used);
- It slows down considerably for huge arrays (or, at least you have to build your own hash structure with some pretty hashing function);
Assuming the hash can fit in memory, it has roughtly constant time for lookups; there is no need for a pretty hashing function as such a function is already used interally - that's why it's called a hash!

Dave.