# @param {TreeNode} root # @return {Integer} def max_depth(root) return 0 unless root [max_depth(root.left),max_depth(root.right)].max+1 end


노드 0개짜리 (= 루트조차 null인) 이진트리를 입력으로 주겠다는 생각은 대체 누가 한 건지 의문