Consider the following key values: 66 47 87 90 126 140 145 153 177 285 393 395 4
ID: 3917416 • Letter: C
Question
Consider the following key values: 66 47 87 90 126 140 145 153 177 285 393 395 467 566 620 735 Part A: Store the key values in a hash table (given below) if size 20 locations (indexed 1..20) using division hashing method and linear probing for collision resolution. Use the table below to store the hashed values. Part B: Complete the following table showing the number of comparisons (probs) needed to find each value using the hash function used in Part A above. Consider the following key values: 66 47 87 90 126 140 145 153 177 285 393 395 467 566 620 735 Part A: Store the key values in a hash table (given below) if size 20 locations (indexed 1..20) using division hashing method and linear probing for collision resolution. Use the table below to store the hashed values. Part B: Complete the following table showing the number of comparisons (probs) needed to find each value using the hash function used in Part A above. Part A: Store the key values in a hash table (given below) if size 20 locations (indexed 1..20) using division hashing method and linear probing for collision resolution. Use the table below to store the hashed values. Part B: Complete the following table showing the number of comparisons (probs) needed to find each value using the hash function used in Part A above.Explanation / Answer
NOTE: Here you mentioned to start index from 1. So for 140 the reminder is 0 but we don t have that cell so again i probed and got reminder 1 so inserted at index 1. I do same for the remaining also when i got 0.
1st column -- Index
2nd column -- value
3rd column -- No of comparisions required to find that value
1 140 2 2 620 3 3 4 5 145 1 6 66 1 7 47 1 8 87 2 9 126 4 10 90 1 11 285 7 12 467 6 13 153 1 14 393 2 15 395 1 16 566 11 17 177 1 18 735 4 19 20Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.