Given a hash table with n keys and m slots with simple uniform hashing. If collisions are resolved by chaining then what is the probability that the first slot ends up empty ?
(A) (1 / m)n
(B) [1 – (1/m)]n
(D) [1 – (1/n)]m
Explanation: Probability of one particular slot = 1/m ( because total m slots)
Probability that a value should not go in one particular slot = 1 – (1/m)
For n values (keys) probability = [1 – (1/m)]n
Quiz of this Question