Question: Project 2: Hash Table (in C++): You are to implement a hash table (an ID array of ordered linked list) of B buckets, fThe bucket
Project 2: Hash Table (in C++): You are to implement a hash table (an ID array of ordered linked list) of B buckets, fThe bucket size, B, will be given via argv[2] in command line. The hash function for the hash table is the "Doit" function given in the lecture note and have discuss in the lecture. The input to your program is a text file contains a list of triplets where op is cither + or -or?: + means insert - means delete, and ? means information retrieval; firstName and lastName are character strings. lastName in the triplet is the key passes to the hash function to get the bucket index from the hash function for information storage and retrieval. eeeeee Add the following into your #include: #include using namespace std; What your program will perform: 1. Read the input triplet: op firstName lastName 2. if op is to get the index from Doit(lastName), then, go to hashTable[index] to perform insertion process If op is -, get the index from DoitlastName), then, go to hashTable[index] to perform deletion process If op is ? get the index from DoitlastName), then, go to hashTable[index] to perform information retrieval process 3. output the results to outFiles. 4. Run your program twice, first with bucket size = 29 and next with bucket size 43. 5. Include in your hard copy pdf file: - 1 page cover page - source code - outFilel with bucket size=29 - outFile2 with bucket size=29 - outFilel with bucket size=43 - outFile2 with bucket size=43 Language: C++ Project points: 10 pts Due Date: Soft copy (zip) and hard copies (.pdf): -02/20/2021 Saturday before midnight -1 for 1 day late: 2/21/2021 Sunday before midnight -2 for 2 days late: 2/22/2021 Monday before midnight -10/10:2/22/2021 Monday after midnight *** Name your soft copy and hard copy files using the naming convention as given in the project submission requirement discussed in a lecture and is posted in Google Classroom. *** All on-line submission MUST include Soft copy (zip) and hard copy (pdf) in the same email attachments with correct email subject as stated in the email requirement; otherwise, your submission will be rejected. 1. Inputs: There will be two inputs to the program: a) inFile (use argv[1]): A text file contains a list of triplets { where op is cither + or -or?: + means insert - means delete, and ? means information retrieval; firstName and lastName are character strings. lastName in the triplet is the key passes to the hash function to get the bucket index from the hash function for information storage and retrieval. eeeeee Add the following into your #include: #include using namespace std; What your program will perform: 1. Read the input triplet: op firstName lastName 2. if op is to get the index from Doit(lastName), then, go to hashTable[index] to perform insertion process If op is -, get the index from DoitlastName), then, go to hashTable[index] to perform deletion process If op is ? get the index from DoitlastName), then, go to hashTable[index] to perform information retrieval process 3. output the results to outFiles. 4. Run your program twice, first with bucket size = 29 and next with bucket size 43. 5. Include in your hard copy pdf file: - 1 page cover page - source code - outFilel with bucket size=29 - outFile2 with bucket size=29 - outFilel with bucket size=43 - outFile2 with bucket size=43 Language: C++ Project points: 10 pts Due Date: Soft copy (zip) and hard copies (.pdf): -02/20/2021 Saturday before midnight -1 for 1 day late: 2/21/2021 Sunday before midnight -2 for 2 days late: 2/22/2021 Monday before midnight -10/10:2/22/2021 Monday after midnight *** Name your soft copy and hard copy files using the naming convention as given in the project submission requirement discussed in a lecture and is posted in Google Classroom. *** All on-line submission MUST include Soft copy (zip) and hard copy (pdf) in the same email attachments with correct email subject as stated in the email requirement; otherwise, your submission will be rejected. 1. Inputs: There will be two inputs to the program: a) inFile (use argv[1]): A text file contains a list of triplets {