Search
⌘K

Leetcode 113. Path Sum II

Find all root-to-leaf paths in a binary tree whose node values sum to targetSum, returning each path as a list of values. This is solved with DFS/backtracking that accumulates the running sum (note values may be negative and tree size ≤ 5000).

Asked at:

Meta

Microsoft

Microsoft

Amazon

Amazon


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Late October, 2025

Microsoft

Microsoft

Mid-level

Early May, 2025

Meta

Mid-level

Late August, 2024

Amazon

Amazon

Intern

Path Sum II (LeetCode 113)

Comments

Your account is free and you can post anonymously if you choose.