Write a program to do the following: Use the same input seed data as seed input data into a hash table. Declare a hash table of size 29 elements. To hash your currency objects into the hash table, use...

1 answer below »

Write a program to do the following:



  1. Use the same input seed data as seed input data into a hash table.

  2. Declare a hash table of size 29 elements.

  3. To hash your currency objects into the hash table, use the pseudorandom hash scheme - (m*w +n*f) % size - where size = 29, m = 2, n = 3, w = whole value, f = fractional value.

  4. For collision resolution, use quadratic probing in the same direction always. Remember to circle around to the start of the array if needed.

  5. Your main will first load the data file into the hash table and print the number of data items loaded, load factor and number of collisions.

  6. Then it will ask the user in a loop to enter a Dollar to search for. If the Dollar object is found in the hash table, it will print the index where found, otherwise it will print 'Invalid Data'. Then it will ask the user if they want to check again or end the program.

  7. To submit, upload your code files and screenshot of the console only.

  8. For documentation, only name blocks and existing documentation in your Dollar class are needed.






here is the Seed Data



  1. $57.12

  2. $23.44

  3. $87.43

  4. $68.99

  5. $111.22

  6. $44.55

  7. $77.77

  8. $18.36

  9. $543.21

  10. $20.21

  11. $345.67

  12. $36.18

  13. $48.48

  14. $101.00

  15. $11.00

  16. $21.00

  17. $51.00

  18. $1.00

  19. $251.00

  20. $151.00



Answered Same DayNov 26, 2021

Answer To: Write a program to do the following: Use the same input seed data as seed input data into a hash...

Sathishkumar answered on Nov 27 2021
123 Votes
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here