Question: Q1: This question is about a chaining hash table that has 5 slots and starts off empty. What is the probability that the first two

Q1:

This question is about a chaining hash table that has 5 slots and starts off empty.

What is the probability that the first two items added to the table end up in the same slot and the third item ends up in a different slot to the first two.

The table will end up something like the following:

... slot x: item 1, item 2 ... slot y: item 3 ... 

Where x and y could be any slot in the table.

Similarly,

Q2:

This question is about a chaining hash table that has 5 slots and starts off empty.

What is the probability that the first two items added to the table end up in the same slot and the third and fourth items ends up in a different slot to the first two.

For example the table could end up something like:

... slot x: item 1, item 2 ... slot y: item 3, item 4 ... 

Q3:

This question is about a chaining hash table that has 4 slots and starts off empty.

What is the probability that the first three items that are added to the hash table such that two of them end up in one slot and the other ends up in different slot.

For example the table could end up in any of the following states

slotx: item1, item3 ... sloty: item2 

or

slotx: item1 ... sloty: item2, item3 

or

slotx: item1, item3 ... sloty: item2 

Q4:

This question is about a chaining hash table that has 13 slots and starts off empty.

What is the probability that the first seven items that are added to the hash table all end up in the same slot.

Q5:

This question is about a chaining hash table that has 8 slots and starts off empty.

What is the probability that the first four items that are added to the hash table all end up in different slots.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!