Not trying the be bossy or rude...but please look at my question...my tree CAN be uniquely determined from the preorder because I have information about internal nodes and leaves.Its a huffman tree.
A
aksgh
@aksgh
Posts
-
Binary Tree from preorder traversal -
Binary Tree from preorder traversalummmm...those are tree traversals I need to construct my tree FROM a preorder traversal
-
Binary Tree from preorder traversalHi, I have a tree such that it can be uniquely determined from its preorder.I have information on which are internal nodes and which are leaves.Something like this ----0 ----/-\ ---0--0 --/-\--/-\ -1--0-1--1 ----/-\ ----1--1 the preorder being 001011011 I need some logic to get the tree structure from this preorder
-
Huffman coding IssueHi, I'm coding huffman and have a doubt.I'm writing the preorder version of my huffman tree in term of 0's and 1's as the header of my encoded file.How do I know when my header ended and my encoded data started?