CPSC131
Question Description
I’m trying to study for my Computer Science course and I need some help to understand this question.
Hash table 2 page homework
thank you for your help,
feel free to ask me anything
Unformatted Attachment Preview
Purchase answer to see full attachment

Final Answer

Attached.
CPSC 131 Homework 10
#1 [3 points]
Sketch a hash table of size N=11, where the hash function is hash(key) = key mod N and chaining is
used to resolve collisions, after the following elements are inserted:
20, 42, 45, 49, 62, 72, 95
sing chaining:
---------------0
->
1
-> 45
2
->
3
->
4
->
5
-> 49
6
-> 72
7
-> 62, 95
8
->
9
-> 20, 42
10
->
Index
0
Value
1
2
45
3
4
5
49
6
7
72 62, 95
8
9
10
20,42
#2 [3 points]
Sketch a hash table of size N=11, where the hash function is hash(key) = key mod N and linear
probing is used to resolve collisions, after the following elements are inserted:
20, 42, 45, 49, 62, 72, 95
The H...
