
Interval
violet_program
这个作者很懒,什么都没留下…
展开
-
Merge Intervals
Given a collection of intervals, merge all overlapping intervals. For example, Given [1,3],[2,6],[8,10],[15,18], return [1,6],[8,10],[15,18]. /** * Definition for an interval. * public class Int原创 2013-06-08 02:57:13 · 504 阅读 · 0 评论 -
Insert Intervals
Given a set of non-overlapping intervals, insert a new interval into the intervals (merge if necessary). You may assume that the intervals were initially sorted according to their start times. Examp原创 2013-06-08 03:34:29 · 620 阅读 · 0 评论 -
[Random Coding]Interval Related Questions
import java.util.ArrayList; import java.util.Collections; import java.util.Comparator; import java.util.PriorityQueue; public class WeightedInterval { public static class Interval { int start; i原创 2013-11-11 11:29:52 · 790 阅读 · 0 评论