3 ms·
You could do that and also use a real hash for longer inputs. Literally truncating the input wouldn’t be great in the likely case that your hash table is using
by iainmerrick 8y ago
You could do that and also use a real hash for longer inputs.
Literally truncating the input wouldn’t be great in the likely case that your hash table is using only 10 bits (say) of the hash value, but I bet there are similar approaches that would work.