Hi All
I recently studied about "Forest" Datastructures.
Supposed we have two trees. Could not represent diagramatically
Tree a
======
1) 10 is the root node
2) 9 is the
Tree a Tree b
===== =====
10 5
/ \ / \
9 20 4 7
These are my doubts
1) Is forest applicable for General trees.
2) I read that in "Forest" second tree(Tree b) will be attached as a right child to the first tree (Tree a)
3) How can I attach "Tree b" to "Tree a".
Should I make RIGHT CHILD of node "20" of "Tree a" to point to "Tree b".
4) If I do like that then it violates the binary trees basic principle.
As node "5" of Tree b is less that node "20" of Tree a.
Please clarify my doubts.
Thanks & Regards
Sathish Kumar
I recently studied about "Forest" Datastructures.
Supposed we have two trees. Could not represent diagramatically
Tree a
======
1) 10 is the root node
2) 9 is the
Tree a Tree b
===== =====
10 5
/ \ / \
9 20 4 7
These are my doubts
1) Is forest applicable for General trees.
2) I read that in "Forest" second tree(Tree b) will be attached as a right child to the first tree (Tree a)
3) How can I attach "Tree b" to "Tree a".
Should I make RIGHT CHILD of node "20" of "Tree a" to point to "Tree b".
4) If I do like that then it violates the binary trees basic principle.
As node "5" of Tree b is less that node "20" of Tree a.
Please clarify my doubts.
Thanks & Regards
Sathish Kumar
Comment