-
Notifications
You must be signed in to change notification settings - Fork 32
traverse all descendants of a node #28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Yes, that's not difficult. If
The |
Hello, root | +----A | | | +---B | | | | | +---B1 | | | +---C | | | +---C1 | | | +---C2 +----D | +---E | +---F |
I use |
I see, thank you so much for your clear explanation. |
I also have another question: |
Hello
I am wondering if it is possible to traverse all the descendants including children, greatchildren, greatgreatchildren, and so on, of a particular node?
eg. how to only traverse the B1, B, C1, C2 and C through post iterator or B, B1, C and C1, C2 through pre iterator of the node A in this tree? (through a subtree of A could not be the best of my needs)
root
|
+----A
| |
| +---B
| | |
| | +---B1
| |
| +---C
| |
| +---C1
| |
| +---C2
+----D
|
+---E
|
+---F
Thank you.
The text was updated successfully, but these errors were encountered: