anholt/hash_table

Q: when is deleted entry reused?

Closed this issue · 1 comments

Hi,

The readme says that:

When an insert collides, the insert
steps through the table using the reprobe stride until a free or dead entry is
found. 

But reading the code is my understanding correct that deleted entries are only reused if a free slot is not found?
If so, I am curious why.

I think I understand it now, the chain has to be followed until the end, as there could be an entry after a deleted one that matches the key.