363. Meeting Rooms III
You are given an integer `n`. There are `n` rooms numbered from `0` to `n - 1`. You are given a 2D integer array `meetings` where `meetings[i] = [start_i, end_i]` means that a meeting will be held during the **half-closed** time interval `[start_i, end_i)`. All the values of `start_i` are **unique**. Meetings are allocated to rooms in the following manner: 1. Each meeting will take place in the **unused** room with the **lowest** number. 2. If there are no available rooms, the meeting will be delayed until a room becomes free. The delayed meeting should have the **same** duration as the original meeting. 3. When a room becomes unused, meetings that have an earlier original **start** time should be given the room. Return the **number** of the room that held the most meetings. If there are multiple rooms, return the room with the **lowest** number.
Examples
Input: 2 [[0,10],[1,5],[2,7],[3,4]]
Output: 0
Explanation: Rooms 0 and 1 each hold 2 meetings; the tie goes to the lower room number, 0.
Constraints
- 1 <= n <= 100
- 1 <= meetings.length <= 10^5
- meetings[i].length == 2
- 0 <= start_i < end_i <= 5 * 10^5
- All the values of start_i are unique.
Run checks all cases above. Submit evaluates all test cases.