Quadratic probing
Suppose that we are given a key k to search for in a hash tablewith positions
0, 1, ..., m - 1 and suppose that we have a hash function h mappingthe key
space into the set 0, 1, ..., m - 1} The search scheme is asfollows.
1. Compute the value i ← h(k), and set j ← 0
2. Probe in position i for the desired key k. If you findit, or if this position is
empty, terminate the search.
3. Set j ← ( j + 1) mod m and i ←(i + j ) mod m,and return to step 2.
Assume that m is a power of 2.
a. Show that this scheme is an instance of the generalquadratic probing scheme
by exhibiting the appropriate constants c1 and c2 forequation (11.5).
[equation 11.5 is this]
h(k, i ) = (h′(k) + c1 * i + c2 * i^2)mod m
b. Prove that this algorithm examines every table position in theworst case.
I need help with part b...
Thanks in advance