Task on Hashing Given an array containing Strings, you need to write a code to store them in a hashtable. Assume that the Strings contain a combination of capital letters and numbers, and the String...


Task on Hashing<br>Given an array containing Strings, you need to write a code to store them in a<br>hashtable. Assume that the Strings contain a combination of capital letters and<br>numbers, and the String array will contain no more than 9 values.Use the hash<br>function to be the<br>(total number of consonants*24 + summation of the digits) %9. In case of a<br>collision, use linear probing.<br>For a String

Extracted text: Task on Hashing Given an array containing Strings, you need to write a code to store them in a hashtable. Assume that the Strings contain a combination of capital letters and numbers, and the String array will contain no more than 9 values.Use the hash function to be the (total number of consonants*24 + summation of the digits) %9. In case of a collision, use linear probing. For a String "ST1E89B8A32", it's hash function will produce the value=(3*24+(1+8+9+8+3+2))%9=4, hence it will be stored in index 4 of the hash table.

Jun 05, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here