LeetCode --- 110. Balanced Binary Tree

题目链接:Balanced Binary Tree Given a binary tree, determine if it is height-balanced. For this problem, a height-balanced binary tree is defined as a ...

2015-04-23 10:19:17

阅读数 794

评论数 0

LeetCode --- 109. Convert Sorted List to Binary Search Tree

题目链接:Convert Sorted List to Binary Search Tree Given a singly linked list where elements are sorted in ascending order, convert it to a height bal...

2015-04-17 16:48:22

阅读数 1599

评论数 0

LeetCode --- 108. Convert Sorted Array to Binary Search Tree

题目链接:Convert Sorted Array to Binary Search Tree Given an array where elements are sorted in ascending order, convert it to a height balanced BST. ...

2015-04-17 16:47:29

阅读数 776

评论数 0

LeetCode --- 107. Binary Tree Level Order Traversal II

题目链接:Binary Tree Level Order Traversal II Given a binary tree, return the bottom-up level order traversal of its nodes' values. (ie, from left to ...

2015-04-17 16:46:33

阅读数 2430

评论数 0

LeetCode --- 106. Construct Binary Tree from Inorder and Postorder Traversal

题目链接:Construct Binary Tree from Inorder and Postorder Traversal Given inorder and postorder traversal of a tree, construct the binary tree. Note:...

2015-04-17 16:44:25

阅读数 650

评论数 0

LeetCode --- 105. Construct Binary Tree from Preorder and Inorder Traversal

题目链接:Construct Binary Tree from Preorder and Inorder Traversal Given preorder and inorder traversal of a tree, construct the binary tree. Note: ...

2015-04-16 09:13:20

阅读数 690

评论数 0

LeetCode --- 104. Maximum Depth of Binary Tree

题目链接:Maximum Depth of Binary Tree Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from...

2015-04-16 09:12:17

阅读数 966

评论数 0

LeetCode --- 103. Binary Tree Zigzag Level Order Traversal

题目链接:Binary Tree Zigzag Level Order Traversal Given a binary tree, return the zigzag level order traversal of its nodes' values. (ie, from left to...

2015-04-16 09:11:31

阅读数 827

评论数 0

LeetCode --- 102. Binary Tree Level Order Traversal

题目链接:Binary Tree Level Order Traversal Given a binary tree, return the level order traversal of its nodes' values. (ie, from left to right, level by...

2015-04-16 08:57:30

阅读数 663

评论数 0

LeetCode --- 101. Symmetric Tree

题目链接:Symmetric Tree Given a binary tree, check whether it is a mirror of itself (ie, symmetric around its center). For example, this binary tree is...

2015-04-16 08:55:14

阅读数 775

评论数 0

LeetCode --- 100. Same Tree

题目链接:Same Tree Given two binary trees, write a function to check if they are equal or not. Two binary trees are considered equal if they are struct...

2015-04-14 19:54:07

阅读数 814

评论数 0

LeetCode --- 99. Recover Binary Search Tree

题目链接:Recover Binary Search Tree Two elements of a binary search tree (BST) are swapped by mistake. Recover the tree without changing its structure....

2015-04-14 19:52:24

阅读数 647

评论数 0

LeetCode --- 98. Validate Binary Search Tree

题目链接:Validate Binary Search Tree Given a binary tree, determine if it is a valid binary search tree (BST). Assume a BST is defined as follows: T...

2015-04-14 19:51:33

阅读数 715

评论数 0

LeetCode --- 97. Interleaving String

题目链接:Interleaving String Given s1, s2, s3, find whether s3 is formed by the interleaving of s1 and s2. For example, Given: s1 = "aabcc"...

2015-04-14 19:50:56

阅读数 671

评论数 0

LeetCode --- 96. Unique Binary Search Trees

题目链接:Unique Binary Search Trees Given n, how many structurally unique BST's (binary search trees) that store values 1...n? For example, Given n = ...

2015-04-14 19:49:55

阅读数 721

评论数 0

LeetCode --- 95. Unique Binary Search Trees II

题目链接:Unique Binary Search Trees II Given n, generate all structurally unique BST's (binary search trees) that store values 1...n. For example, Giv...

2015-04-09 10:53:49

阅读数 769

评论数 0

LeetCode --- 94. Binary Tree Inorder Traversal

题目链接:Binary Tree Inorder Traversal Given a binary tree, return the inorder traversal of its nodes' values. For example: Given binary tree {1,#,2,3...

2015-04-09 10:52:13

阅读数 639

评论数 0

LeetCode --- 93. Restore IP Addresses

题目链接:Restore IP Addresses Given a string containing only digits, restore it by returning all possible valid IP address combinations. For example: ...

2015-04-09 10:51:20

阅读数 1058

评论数 0

LeetCode --- 92. Reverse Linked List II

题目链接:Reverse Linked List II Reverse a linked list from position m to n. Do it in-place and in one-pass. For example: Given 1->2->3->4->...

2015-04-09 10:50:21

阅读数 524

评论数 0

LeetCode --- 91. Decode Ways

题目链接:Decode Ways A message containing letters from A-Z is being encoded to numbers using the following mapping: 'A' -> 1 'B' -> 2 ... 'Z...

2015-04-09 10:49:48

阅读数 524

评论数 0

提示
确定要删除当前文章?
取消 删除
关闭
关闭