04-16-2011 08:54 PM
Hello
Could someone plus help me build a tree. What I need is from some input coming in, build a data base as a tree. Please see attachment:
1 he
2 she
3 his
4 hers....
for example if I have the above word coming in, how do I build a tree like the one one the picture?
so basically I have 1 character at a time, after each character is a node. We start from the first word than always go back to the origin to add ather word. at the end of each word add its number...
any help is appreciated. I am creating a database of words a tree.
04-17-2011 04:55 AM
Depends on your LabVIEW skills and performance requirements. It's not a very easy task to implement a by-ref structure in LabVIEW.
Advanced & Slow: Use a by-ref OOP design (DVR).
Simple & a bit faster: Keep all nodes in an array. Each node consists of the key (char, length) and a list (array) containing the indices of 'next nodes' -> together this is a cluster.
Felix