=========================================================================== CSC 263H Tutorial Outline for Week 7 Winter 2004 =========================================================================== ------- Hashing ------- - Exercise R-2.19 on page 132 of the textbook. - Write pseudo-code for performing SEARCH, INSERT, and DELETE on a hash table T of size m, where collisions are resolved using double hashing with primary hash function h and secondary hash function h_2. Assume that the two hash functions are well-designed, i.e., that the probe sequence for any key k is a permutation of the indices 0,1,...,m-1. Assume also that the hash table stores elements x with a key[x] field, following the Dictionary ADT. Hint: For DELETE, you will have to come up with a way of keeping track of the difference between an empty location (where no element has ever been stored) and a deleted location. This was covered in class at the Mississauga and Scarborough campuses, but not on the St. George campus.