leetle

Daily challenge for 2026-01-04

369. Path Sum to Leaf

Given a binary tree represented as an array in level-order (where null represents an empty node), determine if there exists a root-to-leaf path such that the sum of the values along the path equals a given target. A leaf is a node with no children.

Example:
Input: tree = [5,4,8,11,null,13,4], target = 22 Output: true

Run this challenge interactively in Python or JavaScript when the app loads.