Day 26 of June LeetCode Challenge

Aanchal Patial
1 min readJun 26, 2020

--

Given a binary tree containing digits from 0-9 only, each root-to-leaf path could represent a number.

An example is the root-to-leaf path 1->2->3 which represents the number 123.

Find the total sum of all root-to-leaf numbers.

Note: A leaf is a node with no children.

--

--

Aanchal Patial

We never really grow up, we only learn how to act in public