':type root: TreeNode
:rtype: int'

def sumOfLeftLeaves(self, root):

    def sumOfLeftLeavesHelper(root, is_left):
        if (not root):
            return 0
        if ((not root.left) and (not root.right)):
            return (root.val if is_left else 0)
        return (sumOfLeftLeavesHelper(root.left, True) + sumOfLeftLeavesHelper(root.right, False))
    return sumOfLeftLeavesHelper(root, False)
