Minimal Perfect Hashing

Have u heard of 'Minimal Perfect Hashing' , if not , Perfect hashing guarantees that you get no collisions at all. It is possible when you know exactly what set of keys you are going to be hashing when you design your hash function. It's popular for hashing keywords for compilers. (They ought to be popular for optimizing switch statements.) Minimal perfect hashing guarantees that n keys will map to 0..n-1 with no collisions at all

More info here .

0 opinions: