乐趣区
  • 首页
  • 分类
    • javascript
    • 日常
    • html5
    • python
    • app
    • 书评
    • wordpress
  • 我的作品
  • 关于
  • 隐私政策
  • 首页
  • 分类
    • javascript
    • 日常
    • html5
    • python
    • app
    • 书评
    • wordpress
  • 我的作品
  • 关于
  • 隐私政策
  1. 首页
  2. 标签
  3. binary-search
leetcode352-Data-Stream-as-Disjoint-Intervals

java leetcode352-Data-Stream-as-Disjoint-Intervals

这里面提到了一个disjoint interval的概念,它是指不相交的区间。如果新来的数据与当前的区间集产生了重合,则需要将当前的区间集进行合并。从而确保每次得到的数据集都是不相交的。

106次阅读
java 2019-10-12
leetcode436-Find-Right-Interval

java leetcode436-Find-Right-Interval

假设一个二维的整数数组中每一行表示一个区间,每一行的第一个值表示区间的左边界,第二个值表示区间的右边界。现在要求返回一个整数数组,用来记录每一个边界右侧最邻近的区间。

92次阅读
java 2019-07-13
leetcode363-Max-Sum-of-Rectangle-No-Larger-Than-K

java leetcode363-Max-Sum-of-Rectangle-No-Larger-Than-K

现有一个由整数构成的矩阵,问从中找到一个子矩阵,要求该子矩阵中各个元素的和为不超过k的最大值,问子矩阵中元素的和为多少?注:后面的文章中将使用[左上角顶点坐标,右下角顶点坐标]来表示一个矩阵,如[(1,2),…

131次阅读
java 2019-06-07
leetcode410-Split-Array-Largest-Sum

java leetcode410-Split-Array-Largest-Sum

将一个长度为n的正整数数组分割为m个非空的连续子数组,并分别计算每个子数组中所有元素的和。求一种分割方式,使得该分割方式生成的最大子数组和为所有分割方式中最小的。

274次阅读
java 2019-05-19
leetcode378. Kth Smallest Element in a Sorted Matrix

java leetcode378. Kth Smallest Element in a Sorted Matrix

在一个从左到右,从上到下均有序的二维数组中,找到从小到第k个数字,这里需要注意,不要求一定要是唯一的值,即假设存在这样一个序列1,2,2,3,则第三个数字是2而不是3。

52次阅读
java 2019-02-14
[LeetCode] 410. Split Array Largest Sum

java [LeetCode] 410. Split Array Largest Sum

Given an array which consists of non-negative integers and an integer m, you can split the array into m non-empty continuous subarrays. Write an algorithm to minimize the largest sum among these m …

80次阅读
java 2018-12-25
[LeetCode] 702. Search in a Sorted Array of Unknown Size

java [LeetCode] 702. Search in a Sorted Array of Unknown Size

Given an integer array sorted in ascending order, write a function to search target in nums. If target exists, then return its index, otherwise return -1. However, the array size is unknown to you….

79次阅读
java 2018-12-14
版权说明

本站部分资源来自于网络收集,若侵犯了你的隐私或版权,请及时联系我们删除有关信息。联系邮箱:wukuili@gmail.com

鲁ICP备18007129号
 Theme by Puock