in reply to Generating Unique numbers from Unique strings
I believe that if i get a 32bit integer which uniquely defines the string then the storage and comparison operations will be much faster.
That's exactly what a hash does; with the additional benefit that it deals with collisions, if they occur, automatically.
So store your strings in a hash; lookup is very fast and memory management is taken care of.
|
|---|