摘要: LeetCode 110.平衡二叉树 分析1.0 求左子树高度和右子树高度,若高度差>1,则返回false,所以我递归了两遍 class Solution { public boolean isBalanced(TreeNode root) { if(root == null){ return tr 阅读全文
posted @ 2023-02-04 17:44 cupxu 阅读(12) 评论(0) 推荐(0)