LeetCode
文章平均质量分 76
miaowangbing
这个作者很懒,什么都没留下…
展开
-
LeetCode#213. House Robber II
213. House Robber IITotal Accepted: 23996 Total Submissions: 80010 Difficulty: MediumNote: This is an extension of House Robber.After robbing those houses on that street, the thief has found原创 2016-03-16 12:16:44 · 391 阅读 · 0 评论 -
LeetCode#105. Construct Binary Tree from Preorder and Inorder Traversal
105. Construct Binary Tree from Preorder and Inorder TraversalGiven preorder and inorder traversal of a tree, construct the binary tree.Note:You may assume that duplicates do not exist in th原创 2016-03-24 21:32:39 · 293 阅读 · 0 评论 -
LeetCode#104. Maximum Depth of Binary Tree
104. Maximum Depth of Binary TreeGiven 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.原创 2016-03-24 21:19:29 · 364 阅读 · 0 评论 -
LeetCode#101. Symmetric Tree
101. Symmetric TreeGiven a binary tree, check whether it is a mirror of itself (ie, symmetric around its center).For example, this binary tree is symmetric: 1 / \ 2 2 / \ /原创 2016-03-24 21:06:35 · 385 阅读 · 0 评论 -
LeetCode#103. Binary Tree Zigzag Level Order Traversal My Submissions Question
103. Binary Tree Zigzag Level Order Traversal My Submissions QuestionTotal Accepted: 57077 Total Submissions: 201598 Difficulty: MediumGiven a binary tree, return the zigzag level order traversal原创 2016-03-24 21:15:30 · 313 阅读 · 0 评论 -
LeetCode#102. Binary Tree Level Order Traversal My Submissions Question
102. Binary Tree Level Order Traversal My Submissions QuestionTotal Accepted: 96217 Total Submissions: 297797 Difficulty: EasyGiven a binary tree, return the level order traversal of its nodes' va原创 2016-03-24 21:13:30 · 293 阅读 · 0 评论 -
LeetCode#334. Increasing Triplet Subsequence
334. Increasing Triplet SubsequenceGiven an unsorted array return whether an increasing subsequence of length 3 exists or not in the array.Formally the function should:Return true if t原创 2016-03-23 14:19:10 · 353 阅读 · 0 评论 -
LeetCode#338. Counting Bits
338. Counting Bits题目:Given a non negative integer number num. For every numbers i in the range 0 ≤ i ≤ num calculate the number of 1's in their binary representation and return them as an array.原创 2016-03-23 11:25:28 · 307 阅读 · 0 评论 -
LeetCode#120. Triangle
120. TriangleTotal Accepted: 65067 Total Submissions: 219220 Difficulty: MediumGiven a triangle, find the minimum path sum from top to bottom. Each step you may move to adjacent numbers on the r原创 2016-03-16 13:21:42 · 286 阅读 · 0 评论 -
LeetCode#337. House Robber III
337. House Robber IIITotal Accepted: 2052 Total Submissions: 5607 Difficulty: MediumThe thief has found himself a new place for his thievery again. There is only one entrance to this area, calle原创 2016-03-16 12:56:53 · 302 阅读 · 0 评论 -
LeetCode#198. House Robber
You are a professional robber planning to rob houses along a street. Each house has a certain amount of money stashed, the only constraint stopping you from robbing each of them is that adjacent house原创 2016-03-16 11:32:55 · 347 阅读 · 0 评论 -
LeetCode#106. Construct Binary Tree from Inorder and Postorder Traversal
106. Construct Binary Tree from Inorder and Postorder TraversalGiven inorder and postorder traversal of a tree, construct the binary tree.c++代码1:/** * Definition for a binary tree node. * stru原创 2016-03-24 21:35:21 · 370 阅读 · 0 评论