How to keep track of nodes in a tree?
I'm having trouble keeping track of nodes in a tree. I can insert them fine, but when I need to access, modify, or remove a node, I can't figure out to reference the node. Aside from creating a "new Node" for every single Node....
For example, if I have a tree with some root, and attach 5 nodes with elements H, A, P, P, Y one after the other so that Y is a child of P, P is a child of P, P is a child of A, etc...
I'd like to attach H,E,L,L starting from H but I don't know how to reference it. Currently I just have two separate H nodes.