SSplunk·DSAEngineerOnsite – Coding (Practical)
Meeting Rooms II (Min Rooms)
Problem
Given meeting intervals, return the minimum number of rooms required.
Example
[[0,30],[5,10],[15,20]] -> 2
Constraints
- 1 ≤ n ≤ 10^4
Approach
Sort starts/ends, sweep; or min-heap of end times. Reported Splunk question.
added 6 days ago