[prev] 67 [next]

Exercise 8: Linear Probing Example

Consider a linear-probed hash table
  • N = 10 table slots, hash(k) = k%10
Show the result of inserting items with these keys
  1. 1, 2, 3, 4, 5, 6, 7, 8, 9
  2. 15, 6, 20, 3, 17, 14, 33, 5
into an initially empty table