CSS343-A Written Assignment #1

  1. Use Huffman coding to encode these symbols with given frequencies:
    a: 0.10 
    b: 0.25 
    c: 0.05 
    d: 0.15 
    e: 0.30 
    f: 0.07 
    g: 0.08
    
  2. Build (draw) a heap (maxheap, largest value at root) by inserting one item at a time with the values:
    15 20 3 4 8 10 9 5 14 2 25
    
  3. Build (draw) a heap (minheap, smallest value at root) by inserting one item at a time with the values
    10 2 8 6 20 3 5 12 4 10 15 
    
Turn in your completed assignment at the beginning of class on Monday, January 27. Please use standard letter sized paper.