Problem Statement In this project you will be implementing Huffman Coding. You will implement Huffmans Algorithm and fill out the functions in the interface provided on Stepik. You cannot alter the existing interface and must stick to the function and class signatures as on Stepik as we call the respective functions in a main method that is hidden. You can however add more new public or private functions or member variables if necessary. You are also supposed to write a reflection documenting the time complexity of your code and what you learned. Tasks in this project read a file calculate the frequency of each character in the file place the characters and frequencies into a table indexed by the character run the character frequency through Huffmans Algorithm and create a Huffman Tree traverse the Huffman Tree and print out the characters and frequencies read a file and encode the characters in the file using a Huffman Tree decode a string of 1s and Os using a Huffman TreeProject information is found on canvas. Your methods themselves arent expected to output anything if they behave correctly then we will output the right success messages. The tests are predefined on Stepik, and this step only offers an interface to compare your work to what well use for grading. You must develop and ensure functionality on your own. Stepik Input format Input is either a string or a file name containing text which is used to build the Huffman tree followed by an integer representing a test. Your huffman tree itself is expected to only take in text. Stepik reads the file for you. File names are prefixed with / Integers represent the following tests 1. Test 0 tests the lengths of each encode. 2. Test 1 tests the functionality of your decode. 3. Test 2 tests the functionality of extracting individual character codes. Example For example, lets assume input is mississippi 0 Since this is not preceded by /, this is a string and not a filename. A corresponding Huffman tree for mississippi
Only logged in customers who have purchased this product may leave a review.
Reviews
There are no reviews yet.