Skip to content

Beta · Data may be lost.Your data may be reset or lost.

GateBrew
← GATE CSE 2021 Set 1
Questions

Q47

MSQ2 marksAlgorithms

Consider a dynamic\textit{dynamic} hashing approach for 44-bit integer keys: There is a main hash table of size 44. The 22 least significant bits of a key is used to index into the main hash table. Initially, the main hash table entries are empty. Thereafter, when more keys are hashed into it, to resolve collisions, the set of all keys corresponding to a main hash table entry is organized as a binary tree that grows on demand. First, the 3rd3^{\text{rd}} least significant bit is used to divide the keys into left and right subtrees. To resolve more collisions, each node of the binary tree is further sub-divided into left and right subtrees based on the 4th4^{\text{th}} least significant bit. A split is done only if it is needed, i.e., only when there is a collision. Consider the following state of the hash table.

Figure 1

Which of the following sequences of key insertions can cause the above state of the hash table (assume the keys are in decimal notation)?

Sign in to save attempts.

The solution is hidden while you attempt this question. It opens once you check or show the answer.