Sum Root to Leaf Numbers | Recursion | Leetcode

Описание к видео Sum Root to Leaf Numbers | Recursion | Leetcode

This video explains a very important recursion based programming interview problem which is to find the sum of all the numbers formed from a root to leaf path traversal of a binary tree.In this problem, we are given a binary tree and we need to traverse from root to leaf and then form a number.Likewise, repeat the path traversals and form all possible numbers from root to leaf.Finally, find the sum of all these numbers formed and return as answer.I have shown how we can solve this problem using recursion or dfs (depth first search).I have also shown the code walk through at the end of the video.CODE LINK is present below as usual. If you find any difficulty or have any query then do COMMENT below. PLEASE help our channel by SUBSCRIBING and LIKE our video if you found it helpful...CYA :)

=================================================================
INSTAGRAM:   / surya.pratap.k  
LinkedIn:   / surya-pratap-kahar-47bb01168  
WEBSITE: https://techdose.co.in/
=================================================================

CODE LINK: https://gist.github.com/SuryaPratapK/...
OTHER PROOBLEMs:-
Cousins in a binary tree:    • Cousins in a binary tree | Leetcode #993  
Invert Binary Tree:    • Invert Binary Tree | Leetcode #226  
Search in a Binary Search Tree:    • Search in a Binary Search Tree | Leet...  
Count Complete Tree Nodes:    • Count Complete Tree Nodes | Leetcode ...  

Комментарии

Информация по комментариям в разработке