← 返回 netflix 的题目列表Meeting Rooms (Conflict Check)
类型:qbank
Given meeting intervals, decide if one person can attend all of them with no overlap; an end time equal to the next start is not a conflict.
Problem Requirements
You are given a list of meeting time intervals. Each interval has a specific start time and end time.
Your task is to check if a person can attend all the meetings in the list. This is only possible if there are no time conflicts (overlaps) between any of the meetings.
Note: If one meeting ends at the exact same time the next one starts (for example, one ends at 8 and the next starts at 8), this is not considered a conflict.
Sample Cases
Case 1:
Input: intervals = [(0,30),(5,10),(15,20)]
Output: false
Reasoning:
The meeting (0,30) overlaps with (5,10).
The meeting (0,30) also overlaps with (15,20).
Case 2:
Input: intervals = [(5,8),(9,15)]
Output: true
Input Limits
The list will contain between 0 and 500 meetings (0 <= intervals.length <= 500).
Start and end times will be between 0 and 1,000,000.