Answered step by step
Verified Expert Solution
Question
1 Approved Answer
2 Practice with Hash Tables (24 pts) Hashing with Chaining (a) (6 pts) Fill in the table below after inserting 20, 51, 10, 19, 32,
2 Practice with Hash Tables (24 pts) Hashing with Chaining (a) (6 pts) Fill in the table below after inserting 20, 51, 10, 19, 32, 1, 66, 40 (in this order) into an initially empty hash table of size 11 with chaining and h(k)=kmod11. Open Addressing with Linear Probing (b) (6 pts) Fill in the table below after inserting 20, 51, 10, 19, 32, 1, 66, 40 (in this order) into an initially empty hash table of size 11 with linear probing and h(k,i)h(k)=(h(k)+i)mod11=kmod11 1 (c) (3 pts) How many re-hashes after collision are required for this set of keys? Show your work! Open Addressing with Double Hashing (d) (6 pts) Fill in the table below after inserting 20, 51, 10, 19, 32, 1, 66, 40 (in this order) into an initially empty hash table of size m=11 with double hashing and h(k,i)h1(k)h2(k)=(h1(k)+ih2(k))mod11=kmod11=1+(kmod7) (e) (3 pts) How many re-hashes after collision are required for this set of keys? Show your work
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