0. 题目
1. 递归 o(n) o(height)
class Solution(object):
def maxDepth(self, root):
if not root: return 0
return max(self.maxDepth(root.left),self.maxDepth(root.right))+1
class Solution(object):
def maxDepth(self, root):
if not root: return 0
return max(self.maxDepth(root.left),self.maxDepth(root.right))+1