You are viewing a single comment's thread. Return to all comments →
This doesn't work for the case when the input is only one char. Easy fix: check if the root is a leaf before anything else.
Tree: Huffman Decoding
You are viewing a single comment's thread. Return to all comments →
This doesn't work for the case when the input is only one char. Easy fix: check if the root is a leaf before anything else.