Question: Hash Functions You will be writing 2 different hash functions ( at least ) for the purposes of comparing their efficiency. You may use any

Hash Functions
You will be writing 2 different hash functions (at least) for the purposes of comparing their efficiency. You may use any hash function youd like as long as theyre not ridiculously bad (you should not hash on just the first letter of the word, you should not hash every word to the same index, etc.). You are aiming to have as few collisions as possible, so remember that your array could be quite large, and be wary of the challenges of hashing string keys and the range of numbers your hash function is able to produce. Additionally, your hash functions should be different enough from each other; you shouldnt have one be adding the values of the first 3 characters and the second be adding the values of the first 4 characters. Feel free to combine some of the various hash functions described in class, but try to limit the number of operations to some sort of constant.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Your question about creating two different hash functions for comparison is clear and complete Below I will outline how you can create and compare two ... View full answer

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 Databases Questions!