Path Sum
LinkedIn Interview Question
Problem Overview
Difficulty: Easy
LeetCode Pattern: DFS
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.
Note: A leaf is a node with no children.
Tree:
1
/ \
2 3
/ \
4 5
Example 1:
· Input: targetSum = 9
· Output…


