Question
Consider the recursive split order algorithm with closed Hashmap. Let there be four physical buckets. The questions are NOT independent. They should be done sequentially.
Consider the recursive split order algorithm with closed Hashmap. Let there be four physical buckets. The questions are NOT independent. They should be done sequentially. ? The state after the operations in (a) must be used in (b), which should be used in (c).
a) Assume that only bucket 0 is initialized. If the hash set stores items with regular keys 0, 2, 4, 8, 12, and 20, what would be the organization of the hash set? Show all buckets, sentinel and regular keys and links. ?
b) Suppose that bucket size is now increased to 4. An item with key 6 is added. What would be the organization of the data structure? Show all buckets, sentinel and regular keys and links. ?
c) Suppose we add an item with regular key 15 to this hash set. Show the structure of the hash set after the addition. Show all buckets, sentinel and regular keys and links. ?
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started