题目描述
Problem Description
You have scheduled to attend $ N $ online meetings. The $ i $th meeting is scheduled to be held from $ S_i $ o'clock to $ T_i $ o'clock $ D_i $ days from today.
Determine if there are any overlapping meeting schedules. However, if the end time of one meeting is the same as the start time of another meeting, it is not considered overlapping.
Input Format
The input is given from the standard input in the following format:
$ N $ $ D_1 $ $ S_1 $ $ T_1 $ $ D_2 $ $ S_2 $ $ T_2 $ $\vdots$ $ D_N $ $ S_N $ $ T_N $
Output Format
If there are overlapping meeting schedules, output Yes. If there are no overlapping schedules, output No.
Sample Input and Output
Sample Input #1
3
1 10 15
1 11 12
1 14 16
Sample Output #1
Yes
Sample Input #2
3
1 20 22
1 22 24
2 0 2
Sample Output #2
No
Sample Input #3
5
2 0 24
1 0 10
3 0 1
1 12 23
3 22 24
Sample Output #3
No
Notes/Hints
Constraints
- All inputs are integers.
- $1 \leq N \leq 10^5$
- $1 \leq D_i \leq 10^5$
- $0 \leq S_i < T_i \leq 24$
Sample Explanation 1
The $ 1 $st and $ 2 $nd meetings, and the $ 1 $st and $ 3 $rd meetings overlap.
Sample Explanation 2
The $ 1 $st meeting is immediately followed by the $ 2 $nd meeting, and the $ 2 $nd meeting is immediately followed by the $ 3 $rd meeting, but they do not overlap.
输入格式
见题面 Input 部分
输出格式
见题面 Output 部分