Loading visualizer…
Visualize hierarchical structures and traversals: Pre, In, Post, and Level order.
Variants
Left → Root → Right. Visits nodes in ascending order on a BST.
Root → Left → Right. Clones a tree or serialises expression trees.
Left → Right → Root. Bubble information up from children — the basis of every post-order pattern.
DFS the tree with a running sum; light up any root-to-leaf path that hits the target.
Recursive descent — both subtrees returning truthy at a node means that node is the LCA.
Variants
Level-order traversal counting completed levels — every fully drained queue level bumps the depth counter.