Relative Content

Tag Archive for recursiontail-recursion

the way of think about recursion

so i was doing leetcode 112.path sum,the question is that
Given the root of a binary tree and an integer targetSum, return true if the tree has a root-to-leaf path such that adding up all the values along the path equals targetSum.