Question: 3. Suppose that we hash 5 items into a table with 5 slots using a random hash function that maps every item to each slot

3. Suppose that we hash 5 items into a table with 5 slots using a random hash function that maps every item to each slot with the same probability, independent of the other items. Consider the probability that all the five items are mapped to distinct slots; is this probability close to:
A; 40%
B: 10%
C: 4%
D: 1%
point possible (graded) Suppose we want to hash the telephone numbers of the employees of a company using only some of the digits in the number. The phone numbers have the format (xxx)xxxxxxx; the first three digits are the area code and the next three digits indicate the local telephone exchange. Is it better to use a hash function based on: the first three digits? the next three digits? the last three digits? You have used 0 of 1 attempt Multiple Choice 1 point possible (graded) Suppose we use the hash function h(x) x mod 7 (i.e. h(x) is the remainder of the division of x by 7) to hash into a table with 7 slots (the slots are numbered 0,1.., 6) the following numbers: 32, 57, 43, 20, 28, 67, 41, 62, 91, 54. We use chaining to handle collisions. Which slot contains the longest chain? Slot 0 Slot 1 Slot 4 Slot 6
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
