Greedy Algorithms8 sections · 316 units
Open in Course

Problem - Meeting Rooms II

Minimum rooms needed

Given an array of meeting time intervals, find the minimum number of conference rooms required.

For example, [[0,30],[5,10],[15,20]][[0,30],[5,10],[15,20]] needs 22 rooms because the first meeting overlaps with both others, but the second and third do not overlap each other. This is harder than just detecting overlap. You need to count the maximum simultaneous overlaps at any point in time. Think about tracking how many meetings are active as time progresses.