A member of your programming team suggests that your rehash() method first convert the key to a String using its toString() method, then hash on the resulting string. Evaluate this idea. Be sure to justify your claims.

What will be an ideal response?


: If the keys are already integers or characters, then converting to a String is simply extra work as the hashing method will then convert those characters in the String back to their ascii values. Otherwise, the idea would work fine, the folding hash technique could be used and all keys would be hashed in the same manner, producing a more even distribution of hash values.

Computer Science & Information Technology

You might also like to view...

Smart Guides are ________ lines that display on your slide when you are moving an object to assist you with alignment

A) solid B) dotted C) dashed D) double solid

Computer Science & Information Technology

Building Blocks can be saved in a gallery or they can be saved as what?

A) AutoBlock B) DefinedBlock C) AutoText D) DefinedText2

Computer Science & Information Technology

?The ____________________ screen appears when you first start your computer and shows the date and time.

Fill in the blank(s) with the appropriate word(s).

Computer Science & Information Technology

Which of the following ports should be allowed to provide access to certain VoIP applications?

A. 110 B. 139 C. 1720 D. 5060

Computer Science & Information Technology