Perfect Hashing and its implementation