Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21925

Tree structured data question

$
0
0
I want to implement a tree structure similar to the picture:

Attachment 90299

which is not binary.

EDIT: previously unnoticed error => the last generation nodes should be 8, 9 and 10 (actually the values are not relevant to the question)

I'm new to this type of data and don't want to use a Treeview because I don't need to display anything. Id rather settle for something involving less overhead.

If I make it into a class I wonder what is the minimum set of properties I'll need: Parent, LeftChild, RightChild, LeftSibling, RightSibling...

At this stage I'm not quite sure how I'm going to use it since I'm working on a side algorithm but probably I'll have to traverse the structure in all the possible ways from the root to each one of the descendents.
Attached Images
 

Viewing all articles
Browse latest Browse all 21925

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>