May 2019
Intermediate to advanced
698 pages
17h 21m
English
Walking a tree and executing a callback when visiting each node can be done in three ways:
Each of these traversal strategies yields a different order of tree elements, with in-order producing a sorted output, while pre- and post-order create a more structurally oriented sorting. For our users, the in-order walk will provide the best experience, since it also lets them reason better regarding the expected outcome, and, if displayed in a list, it's easier to navigate.
While implementing this walk is very ...
Read now
Unlock full access