摘要:
Given a binary tree, determine if it is height-balanced.For this problem, a height-balanced binary tree is defined as a binary tree in which the depth of the two subtrees of every node never differ by more than 1.class Solution {public: bool f(TreeNode *root, int & height){ if (!root){ ... 阅读全文
posted @ 2013-07-01 23:01
一只会思考的猪
阅读(136)
评论(0)
推荐(0)
浙公网安备 33010602011771号