Question: Algorithm question 0 3. (12 pts) Consider a hash table of size 100 with slots from 1 to 100. Consider the hash function h(k) =
Algorithm question

0 3. (12 pts) Consider a hash table of size 100 with slots from 1 to 100. Consider the hash function h(k) = 100k] for all keys k for a table of size 100. You have three applications. Application 1: Keys are generated uniformly at random from the interval [0.3, 0.8]. Application 2: Keys are generated uniformly at random from the interval (0.1,0.4] U (0.6,0.9). Application 3: Keys are generated uniformly at random from the interval [0, 1]. (a) (3 pts) Suppose you have n keys in total chosen for each application. What is the resulting load factor a for each application? (b) (3 pts) Which application will yield the worst performance? (c) (3 pts) Which application will yield the best performance? (d) (3 pts) Which application will allow the uniform hashing property to apply
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
