#435 - Non-overlapping Intervals
Given an array of intervals intervals[i] = [start, end], return the minimum number of intervals you need to remove to make the rest non-overlapping.
| Input | Output |
|---|---|
intervals = [[1,2],[2,3],[3,4],[1,3]] | 1 |
intervals = [[1,2],[1,2],[1,2]] | 2 |
intervals = [[1,2],[2,3]] | 0 |