Assignment 3 : Due Tuesday, August 1st

General Rules:


1. Program must be written in C++.
2. Must hand in source code, and "script" of program runs.
3. Grades discounted 10% per day late.

Project Description:


Your assignment is to write a small program implements the Huffman Coding Algorithm of Chapter 10.1.2. It should be capable of either a) encoding an unencoded file or b) decoding an encoded file (given the coding information).

You may choose to store the coding information in the same file with the compressed version, or devise some system which uses two files (one encoded; one the coding information) to represent one unencoded file.

Clearly specify in your comments what data structures (and file structures) you have chosen and why.

Your script should show the listing of an unencoded file; the encoded version; and the final, decoded version (which, hopefully matches the original).

You may assume your input file contains only lower case characters, spaces and newlines (in addition to the requisite end-of-file), if you would like.