this program compresses text files using the huffman algorithm. please tell me what you think of it, and any critisism or compliments too.
a couple of things to note:
to run: huff-enc < file_to_compress
this outputs out.ygc, the compressed file, and out.ygt, the lookup table.
then run: huff-dec
this inputs out.ygc and out.ygt and outputs out.ygf, the newly uncompressed file. note: be sure that all 3 output files are deleted before encoding a new file.
because of the size restrictions of this board i haven't included executables with these programs. if you want the executables, see below
huff3.cpp is included into each of the other files. eventually i will link it like a normal program. to compile, just compile huff-enc and huff-dec seperately. remember to keep the huff3.cpp file in the same directory.
don't forget to tell me what you think (if you see bugs, report that too.)
anyone who wants the binaries as well (windows 98 se) can download here:
i've tested it on gcc 2.95.3 on redhat 7.2 linux (successfully), the borland free command line compiler under windows 98 se (successfully), and dev c++ 4 (successfully). borland gives me a fair share of warnings about unsigned to signed conversions, but that's not important.