码迷,mamicode.com
首页 >  
搜索关键字:binary    ( 11734个结果)
leetCode 85.Maximal Rectangle (最大矩阵) 解题思路和方法
Given a 2D binary matrix filled with 0's and 1's, find the largest rectangle containing all ones and return its area. 思路:此题的意思是给一个为0或1的矩阵,求全部为1组成的最大矩阵的面积。 此题可以巧妙转化为求最大直方图面积的问题。 public class S...
分类:其他好文   时间:2015-07-22 14:37:08    阅读次数:98
03-树3. Tree Traversals Again (25)
03-树3. Tree Traversals Again (25) 时间限制 200 ms 内存限制 65536 kB 代码长度限制 8000 B 判题程序 Standard 作者 CHEN, Yue An inorder binary tree traversal can...
分类:其他好文   时间:2015-07-22 10:46:23    阅读次数:303
[leedcode 110] 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 binary tree in which the depth...
分类:其他好文   时间:2015-07-22 01:31:38    阅读次数:118
[leedcode 108] Convert Sorted Array to Binary Search Tree
Given an array where elements are sorted in ascending order, convert it to a height balanced BST./** * Definition for a binary tree node. * public cla...
分类:其他好文   时间:2015-07-21 23:53:37    阅读次数:176
[leedcode 109] Convert Sorted List to Binary Search Tree
Given a singly linked list where elements are sorted in ascending order, convert it to a height balanced BST./** * Definition for singly-linked list. ...
分类:其他好文   时间:2015-07-21 23:47:06    阅读次数:145
[leedcode 107] Binary Tree Level Order Traversal II
Given a binary tree, return thebottom-up level ordertraversal of its nodes' values. (ie, from left to right, level by level from leaf to root).For exa...
分类:其他好文   时间:2015-07-21 23:44:58    阅读次数:124
LeetCode#110 Balanced Binary Tree
Problem Definition:Given a binary tree, determine if it is height-balanced.For this problem, a height-balanced binary tree is defined as abinary tree ...
分类:其他好文   时间:2015-07-21 22:13:12    阅读次数:116
[leedcode 106] Construct Binary Tree from Preorder and Inorder Traversal
Given preorder and inorder traversal of a tree, construct the binary tree.Note:You may assume that duplicates do not exist in the tree./** * Definitio...
分类:其他好文   时间:2015-07-21 22:12:02    阅读次数:108
[leedcode 107] Construct Binary Tree from Inorder and Postorder Traversal
Given inorder and postorder traversal of a tree, construct the binary tree.Note:You may assume that duplicates do not exist in the tree./** * Definiti...
分类:其他好文   时间:2015-07-21 22:02:45    阅读次数:96
LeetCode#112
Problem Definition:Given 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 equa...
分类:其他好文   时间:2015-07-21 21:55:17    阅读次数:105
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!