**Objective: **Given a binary tree, find the sum of all the nodes which are left as well as leaves nodes.

**Example:**

** **

** **

**Approach**:

- Approach is quite simple.
- Do the inorder traversal
- check if node if the left child and leaf node.
- If yes then add it to the sum.
- See the code for more understanding.

**Complete Code:**

**Output:**

Sum of left leaves: 21

Traverse given binary tree using pre order traversal. If current node is left leaf node, then add it’s value to variable sum of left node of binary tree. If current node is not a left leaf node then recursively calculate the sum of left leaf nodes of binary tree in left and right sub tree and return.