1) Design code (object-oriented if you wish, but not required) for processing a hash table with the following specifications: — the records involved simply contain a person’s name (up to 40...

1) Design code (object-oriented if you wish, but not required) for processing a hash table with the following specifications: — the records involved simply contain a person’s name (up to 40 characters) and a three-digit integer key (so, 000 to 999). — the tableSize is to be 19. An array implementation should be used. — your code must provide operations for inserting a record into the table, deleting a record from the table, searching for a given record (if the record is found, report the position in which it was found; otherwise report the failure), building the table from a text file, and displaying a list of the contents of the entire table (including “empty” locations). If a text file is used, each line of the file should contain a name in columns 1 to 40 and a 3-digit integer beginning in column 41 (or later). — The user of the program should be given the option of using linear probing, quadratic probing, or double hashing (with the quotient from key / tableSize used as the secondary hash function) for collision resolution. 2) Write a driver program to test your code. The program should be menu-driven, with options for each of the above operations (and for exit). The program should execute until the user chooses to exit. Note: Your program should report the status (success or failure) of insertions and deletions. For insertions, deletions, and searches, the program should list all positions that were tested, to verify that probing was working properly.
Sep 14, 2021
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here