Data Structures Homework for Week 7. 



This homework is in preparation for quiz #3.

1. Using a heap will make a minimal difference, if any at all, of a "real" Huffman encoder/decoder. Can you explain why?

2. What would be a good hash code for a vehicle identification that is a string of numbers and letters of the form "9X9XX99X9XX999999",
where a "9" represents a digit and an "X" represents a letter?

3. Draw the hash table of length 11 that results from using the hash function

h(i) = (2i + 5) mod 11,

to hash the keys 12, 44, 13, 88, 23, 94, 11, and 39, assuming that collisions are handled by open addressing with linear probing.


All questions below are taken from Adam Drozdek Data structures and algorithms in C++, Course Technology 2005 (3rd ed.).


Ex. 6.12
Question 25.

Ex. 9.7
Question 1.

Ex. 10.7
Question 1.
 

Posted: Thu - February 15, 2007 at 01:46 PM          


©