Trace intervals = [[7,10],[2,4],[5,6]].
Sort by start: [[2,4],[5,6],[7,10]].
Check pairs:
- [2,4] and [5,6]: 5 >= 4. No overlap.
- [5,6] and [7,10]: 7 >= 6. No overlap.
All meetings can be attended. Return true.
Trace [[0,30],[5,10],[15,20]]. After sorting: [[0,30],[5,10],[15,20]].
- [0,30] and [5,10]: 5 < 30. Overlap! Return false.
time for sorting. extra space (or depending on sort).