If every item of the list maps to a unique index in the hash table, then the hash function will be called as ________.
If every item of the list maps to a unique index in the hash table, then the hash function will be called as ________.
Solution
✅ Correct Option: 1
A hash function that maps every item in the list to a unique index, with no two items sharing a slot, is called a perfect hash function. Since there are no collisions, each lookup takes constant time .
Options 2, 3 and 4: "correct", "super" and "right" are not standard terms in hashing.
A perfect hash function needs the set of keys to be known in advance. A minimal perfect hash function also uses a table of exactly the same size as the number of keys.
Related questions:
2025: 14 May Shift 1
2026: 18 May Shift 2