

実行時間制限: 2 sec / メモリ制限: 1024 MiB
配点 : 100 点
問題文
高橋君は
2025 年 5 月 17 日 A 時 B 分締切のレポートを、
2025 年 5 月 17 日 C 時 D 分に提出しました。
ここで、「A 時 B 分」と「C 時 D 分」は異なる時刻であることが保証されます。
高橋君が締切前にレポートを提出しているならば Yes
を、そうでないならば No
を出力してください。
制約
- 0 \leq A,C \leq 23
- 0 \leq B,D \leq 59
- (A,B)\neq(C,D)
- A,B,C,D は整数
入力
入力は以下の形式で標準入力から与えられる。
A B C D
出力
高橋君が締切前にレポートを提出しているならば Yes
を、そうでないならば No
を出力せよ。
入力例 1
22 40 22 30
出力例 1
Yes
レポートの締切は 22 時 40 分であり、高橋君は 22 時 30 分に提出しているため、締切前にレポートを提出しています。
よって、Yes
を出力します。
入力例 2
22 40 22 45
出力例 2
No
レポートの締切は 22 時 40 分であり、高橋君は 22 時 45 分に提出しているため、締切後にレポートを提出しています。
よって、No
を出力します。
入力例 3
12 0 11 30
出力例 3
Yes
Score : 100 points
Problem Statement
Takahashi had a report whose deadline was B minutes past A o'clock on May 17, 2025. He submitted it at D minutes past C o'clock on May 17, 2025.
It is guaranteed that "B minutes past A o'clock" and "D minutes past C o'clock" are different times.
Output Yes
if Takahashi submitted the report before the deadline, and No
otherwise.
Constraints
- 0 \leq A, C \leq 23
- 0 \leq B, D \leq 59
- (A, B) \neq (C, D)
- A, B, C, and D are integers.
Input
The input is given from Standard Input in the following format:
A B C D
Output
If Takahashi submitted the report before the deadline, output Yes
; otherwise, output No
.
Sample Input 1
22 40 22 30
Sample Output 1
Yes
The deadline is 22:40, and he submitted at 22:30, so he submitted before the deadline.
Hence, output Yes
.
Sample Input 2
22 40 22 45
Sample Output 2
No
The deadline is 22:40, and he submitted at 22:45, so he submitted after the deadline.
Hence, output No
.
Sample Input 3
12 0 11 30
Sample Output 3
Yes