Fund. CS II (CS152 2004F)

Homework 42: Conflicts in Hash Tables

Due: Monday, 15 November 2004

I've written a sample implementation of hash tables and a test program. As you may note, the hash table fails to work correctly because it does not attempt to handle conflicts.

Rewrite the code to handle conflicts.

You will need to update set to look in subsequent cells if the current cell is set but not equal.

You will need to update find to look in subsequent cells (until it finds a matching key or an empty cell).

Disclaimer: I usually create these pages on the fly, which means that I rarely proofread them and they may contain bad grammar and incorrect details. It also means that I tend to update them regularly (see the history for more details). Feel free to contact me with any suggestions for changes.

This document was generated by Siteweaver on Wed Dec 8 10:36:57 2004.
The source to the document was last modified on Fri Nov 12 10:43:41 2004.
This document may be found at http://www.cs.grinnell.edu/~rebelsky/Courses/CS152/2004F/Homework/42.html.

You may wish to validate this document's HTML ; Valid CSS! ; Check with Bobby

Samuel A. Rebelsky, rebelsky@grinnell.edu