- 博客(8)
- 问答 (1)
- 收藏
- 关注
原创 96. Unique Binary Search Trees
QGiven n, how many structurally unique BST’s (binary search trees) that store values 1…n?For example, Given n = 3, there are a total of 5 unique BST’s.SCatalan数 参考:http://www.cnblogs.com/NickyYe/p/42
2017-01-23 07:50:43 237
原创 98. Validate Binary Search Tree
QGiven a binary tree, determine if it is a valid binary search tree (BST).Assume a BST is defined as follows:The left subtree of a node contains only nodes with keys less than the node’s key. The righ
2017-01-13 14:54:57 365
原创 113. Path Sum II
TGiven a binary tree and a sum, find all root-to-leaf paths where each path’s sum equals the given sum.S/** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *l
2017-01-06 16:12:10 230
原创 112. Path Sum
TGiven a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum.S/** * Definition for a binary tree node. * struct
2017-01-06 15:43:45 270
原创 111. Minimum Depth of Binary Tree
TGiven a binary tree, find its minimum depth.The minimum depth is the number of nodes along the shortest path from the root node down to the nearest leaf node.S/** * Definition for a binary tree node.
2017-01-06 15:17:04 313
原创 110. Balanced Binary Tree
TGiven 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
2017-01-06 14:33:41 252
原创 104. Maximum Depth of Binary Tree
TGiven a binary tree, find its maximum depth.The maximum depth is the number of nodes along the longest path from the root node down to the farthest leaf node.S/** * Definition for a binary tree node.
2017-01-05 14:29:35 317
原创 101. Symmetric Tree
QGiven a binary tree, check whether it is a mirror of itself (ie, symmetric around its center).For example, this binary tree [1,2,2,3,4,4,3] is symmetric:But the following [1,2,2,null,3,null,3] is not:
2017-01-04 14:47:48 253
空空如也
求帮助:2. Add Two Numbers ,已疯,谢谢
2016-05-19
TA创建的收藏夹 TA关注的收藏夹
TA关注的人