結果

問題 No.1205 Eye Drops
ユーザー ああいいああいい
提出日時 2022-01-27 17:54:55
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 131 ms / 2,000 ms
コード長 361 bytes
コンパイル時間 916 ms
コンパイル使用メモリ 86,988 KB
実行使用メモリ 81,904 KB
最終ジャッジ日時 2023-08-26 18:59:58
合計ジャッジ時間 7,373 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 69 ms
71,272 KB
testcase_01 AC 70 ms
71,336 KB
testcase_02 AC 74 ms
70,980 KB
testcase_03 AC 77 ms
71,064 KB
testcase_04 AC 74 ms
71,092 KB
testcase_05 AC 92 ms
75,344 KB
testcase_06 AC 77 ms
70,964 KB
testcase_07 AC 70 ms
71,136 KB
testcase_08 AC 81 ms
75,324 KB
testcase_09 AC 76 ms
75,312 KB
testcase_10 AC 76 ms
75,268 KB
testcase_11 AC 72 ms
71,104 KB
testcase_12 AC 74 ms
75,004 KB
testcase_13 AC 68 ms
71,216 KB
testcase_14 AC 78 ms
75,272 KB
testcase_15 AC 69 ms
71,112 KB
testcase_16 AC 71 ms
71,136 KB
testcase_17 AC 83 ms
75,008 KB
testcase_18 AC 72 ms
71,028 KB
testcase_19 AC 67 ms
71,100 KB
testcase_20 AC 75 ms
71,116 KB
testcase_21 AC 81 ms
75,224 KB
testcase_22 AC 78 ms
71,216 KB
testcase_23 AC 75 ms
71,240 KB
testcase_24 AC 77 ms
71,144 KB
testcase_25 AC 83 ms
75,172 KB
testcase_26 AC 78 ms
70,964 KB
testcase_27 AC 73 ms
71,012 KB
testcase_28 AC 67 ms
71,032 KB
testcase_29 AC 70 ms
71,176 KB
testcase_30 AC 69 ms
71,236 KB
testcase_31 AC 68 ms
71,100 KB
testcase_32 AC 131 ms
81,904 KB
testcase_33 AC 129 ms
81,836 KB
testcase_34 AC 127 ms
81,896 KB
testcase_35 AC 130 ms
81,892 KB
testcase_36 AC 127 ms
81,788 KB
testcase_37 AC 129 ms
81,804 KB
testcase_38 AC 62 ms
71,216 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N,M = map(int,input().split())
info = []
for _ in range(M):
    t,p = map(int,input().split())
    info.append((t,p))

time = 0
pos = 0
import sys
for t,p in info:
    if time > t:
        print('No')
        exit()
    delta = t - time
    deltapos = abs(p-pos)
    if deltapos > delta:
        print('No')
        exit()
    time = t
    pos = p
print('Yes')
0