Loading page…
Four interview problems answer a question about a whole tree in one pass: the shallowest leaf, paths that sum to a target, the smallest subtree over the deepest leaves, and the best path sum. The move is to return one thing and record the answer aside. The lecture covers the one-child edge case, prefix sums and returning two facts.
Four interview problems sit on this street.