Hash Collision

Many key that goes into a hashing function can come out, that is map to the same integer.

  • Example: if mod

Thus, we get collisions: that is when we want to insert into the table, but is already occupied.

Strategies

  • Closed Hashing: Use some strategy to find another bucket in the table
  • Open Hashing: Each bucket is actually a pointer to short linked list of records

We will look at strategies to resolve collisions!

Hashing with Chaining Probe Sequence Cuckoo Hashing