Given a binary tree, perform pre-order traversal and flatten it to a linked list such that right
for each node is the next node.
Given a tree, compute next
for each node such that each node points to its next
neighbor to the right.
Construct a binary tree from in-order and post-order arrays.
Given a binary tree, check if there’s a path such that a targetSum
can be reached. A target sum is the sum of values of all visited nodes along the path.
Calculate the maximum depth of a binary tree.