码迷,mamicode.com
首页 >  
搜索关键字:largest    ( 1413个结果
Kth Largest Element in an Array
本周学习分治法,故特意挑选了相关习题巩固一下,并回顾一下分治法的思路 题目:Kth Largest Element in an Array Find the kth largest element in an unsorted array. Note that it is the kth large ...
分类:其他好文   时间:2017-03-05 14:20:43    阅读次数:186
SPOJ MINSUB - Largest Submatrix(二分+单调栈)
http://www.spoj.com/problems/MINSUB/en/ 题意:给出一个n*m的矩阵M,和一个面积k,要使得M的子矩阵M'的最小元素最大并且面积大于等于k,问子矩阵M'的最小元素最大能是多少,并且求出最大的面积。 思路:二分一个最小元素x,转化为判断矩阵M里面是否存在一个子矩阵 ...
分类:其他好文   时间:2017-03-04 18:39:51    阅读次数:283
215. Kth Largest Element in an Array
Find the kth largest element in an unsorted array. Note that it is the kth largest element in the sorted order, not the kth distinct element.For examp ...
分类:其他好文   时间:2017-03-01 23:27:35    阅读次数:296
leetcode刷题
2017/3/1 215. Kth Largest Element in an Array Find the kth largest element in an unsorted array. Note that it is the kth largest element in the sorted ...
分类:其他好文   时间:2017-03-01 22:59:41    阅读次数:244
Maximum Product Subarray Leetcode
Find the contiguous subarray within an array (containing at least one number) which has the largest product. For example, given the array [2,3,-2,4],t ...
分类:其他好文   时间:2017-02-26 08:18:51    阅读次数:185
[LeetCode] Find Largest Value in Each Tree Row 找树每行最大的结点值
You need to find the largest value in each row of a binary tree. Example: 这道题让我们找二叉树每行的最大的结点值,那么实际上最直接的方法就是用层序遍历,然后在每一层中找到最大值,加入结果res中即可,参见代码如下: 解法一: ...
分类:其他好文   时间:2017-02-20 00:57:18    阅读次数:159
HDU-5868 Different Circle Permutation
Problem DescriptionYou may not know this but it's a fact that Xinghai Square is Asia's largest city square. It is located in Dalian and, of course, a ...
分类:其他好文   时间:2017-02-03 20:48:18    阅读次数:274
221. Maximal Square
Given a 2D binary matrix filled with 0's and 1's, find the largest square containing only 1's and return its area. For example, given the following ma ...
分类:其他好文   时间:2017-02-03 10:50:18    阅读次数:149
(数组)Largest Rectangle in Histogram(栈解问题)
Largest Rectangle in Histogram Given n non-negative integers representing the histogram's bar height where the width of each bar is 1, find the area o ...
分类:编程语言   时间:2017-01-29 15:26:52    阅读次数:185
53. Maximum Subarray
Find the contiguous subarray within an array (containing at least one number) which has the largest sum. For example, given the array [-2,1,-3,4,-1,2, ...
分类:其他好文   时间:2017-01-29 13:14:15    阅读次数:182
1413条   上一页 1 ... 46 47 48 49 50 ... 142 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!