摘要: 原题链接在这里:https://leetcode.com/problems/lowest-common-ancestor-of-a-binary-tree/ 题目: Given a binary tree, find the lowest common ancestor (LCA) of two g 阅读全文
posted @ 2015-09-05 05:11 Dylan_Java_NYC 阅读(428) 评论(0) 推荐(0)
摘要: 原题链接在这里:https://leetcode.com/problems/lowest-common-ancestor-of-a-binary-search-tree/ 题目: Given a binary search tree (BST), find the lowest common anc 阅读全文
posted @ 2015-09-05 04:52 Dylan_Java_NYC 阅读(306) 评论(0) 推荐(0)
摘要: 原题链接在这里:https://leetcode.com/problems/invert-binary-tree/ 题目: Invert a binary tree. 4 / \ 2 7 / \ / \ 1 3 6 9 to 4 / \ 7 2 / \ / \ 9 6 3 1 题解: 既可以自顶向下 阅读全文
posted @ 2015-09-05 02:27 Dylan_Java_NYC 阅读(170) 评论(0) 推荐(0)
摘要: 原题链接在这里:https://leetcode.com/problems/symmetric-tree/ 题目: Given a binary tree, check whether it is a mirror of itself (ie, symmetric around its center 阅读全文
posted @ 2015-09-05 02:06 Dylan_Java_NYC 阅读(185) 评论(0) 推荐(0)
摘要: 原题链接在这里:https://leetcode.com/problems/binary-tree-level-order-traversal-ii/ 题目: Given a binary tree, return the bottom-up level order traversal of its 阅读全文
posted @ 2015-09-05 01:47 Dylan_Java_NYC 阅读(176) 评论(0) 推荐(0)
摘要: 原题链接在这里:https://leetcode.com/problems/same-tree/ 题目: Given two binary trees, write a function to check if they are equal or not. Two binary trees are 阅读全文
posted @ 2015-09-05 01:24 Dylan_Java_NYC 阅读(286) 评论(0) 推荐(0)
摘要: 原题链接在这里:https://leetcode.com/problems/minimum-depth-of-binary-tree/ 题目: Given a binary tree, find its minimum depth. The minimum depth is the number o 阅读全文
posted @ 2015-09-05 01:07 Dylan_Java_NYC 阅读(265) 评论(0) 推荐(0)
摘要: 原题链接在这里:https://leetcode.com/problems/maximum-depth-of-binary-tree/ 题目: Given a binary tree, find its maximum depth. The maximum depth is the number o 阅读全文
posted @ 2015-09-05 00:49 Dylan_Java_NYC 阅读(263) 评论(0) 推荐(0)
摘要: 原题链接在这里:https://leetcode.com/problems/balanced-binary-tree/ 题目: Given a binary tree, determine if it is height-balanced. For this problem, a height-ba 阅读全文
posted @ 2015-09-05 00:44 Dylan_Java_NYC 阅读(203) 评论(0) 推荐(0)