C
cricketunes
Hey folks
I am implementing the Huffman encoding algorithm. I have created the
tree and its perfect.
Now while searching for a node value, I need to write a 0 to the
encoded file if I am moving left and 1 if I am moving right.
How will I know if I am moving left or right? For instance if I go to
the bottom of the left leaf and its leaflets and then come back and
find the value in one of the right leaves, I shouldnt be having all
those 00000s right?
Appreciate your ideas
Thanks
Crickie
I am implementing the Huffman encoding algorithm. I have created the
tree and its perfect.
Now while searching for a node value, I need to write a 0 to the
encoded file if I am moving left and 1 if I am moving right.
How will I know if I am moving left or right? For instance if I go to
the bottom of the left leaf and its leaflets and then come back and
find the value in one of the right leaves, I shouldnt be having all
those 00000s right?
Appreciate your ideas
Thanks
Crickie