Question: *Question 1) Use the hash function in directory q1 (assign3_q1_hash_chain.cpp), please complete the code in main(). Sample input: 5 lindelof 2 bailly 3 ronaldo 7

 *Question 1) Use the hash function in directory q1 (assign3_q1_hash_chain.cpp), please

*Question 1) Use the hash function in directory q1 (assign3_q1_hash_chain.cpp), please complete the code in main(). Sample input: 5 lindelof 2 bailly 3 ronaldo 7 jones 4 ronaldo 7 Output: 12 23 37 37 The first row in the input file indicates the number of rows in data. The input file contains 5 lines of (name and back number) of football players. For example, Christano Ronaldo have a back number 7 playing for Manchester United (ronaldo 7). Each row will be added to the hash table in order (1, 2, 3, 4 ...) along with the unique back number. If there is a duplicate of player name, then print its adding order (ronald was added at third here) and back numbers. Complete the code and show the result using the data file in the directory. *Question 2) Use another hash function, string_to_hash(), in q2. But this time, just simply print out the player and its corresponding key. e.g.) lindelof 4900454 bailly 109577017 *Question 3) Using files in directory q3, please complete the following: Complete the code for "inOrder', 'postOrder', 'levelOrder', and main() in binary Tree Traversals.cpp. The input tree and output format are described under the comment. Complete your Makefile to compile your code. The empty Makefile is provided in the directory. Please refer to https://www.cs.swarthmore.edu/~newhall/unixhelp/howto_makefiles.html for more information

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!