iSach / huffman-coding-c

C Implementation of the Huffman coding algorithm.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Huffman Coding

This project was done as a class project for the following class: Data Structures and Algorithms (INFO0902-1) It is a C implementation of the huffman coding algorithm.

Grade: 16/20

Running

First, compile:
gcc -o huffman main.c CodingTree.c BinarySequence.c CharVector.c coding.c decoding.c HeapPriorityQueue.c
Then, run:
./huffman [-e] [-d] [-f <eof_char>] [-o <outptPath>] <textPath> <csvPath>

  • -e To encode
  • -d To decode
  • <eof_char> the end of sequence character (Default: 28)
  • -o Output file path
  • textPath: Input file path
  • csvPath the file containing the frequency of each character

Report

The release folder contains a pdf report, answering some theoretical questions about the project. (In French)

Assignment

Click here to see the assignment PDF

About

C Implementation of the Huffman coding algorithm.


Languages

Language:C 99.6%Language:CMake 0.4%