結果

問題 No.2154 あさかつの参加人数
ユーザー w0t0w0t0
提出日時 2022-12-09 21:41:42
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 461 ms / 2,000 ms
コード長 188 bytes
コンパイル時間 315 ms
コンパイル使用メモリ 82,180 KB
実行使用メモリ 81,016 KB
最終ジャッジ日時 2024-04-22 21:26:09
合計ジャッジ時間 12,496 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 461 ms
80,936 KB
testcase_01 AC 430 ms
80,396 KB
testcase_02 AC 416 ms
80,644 KB
testcase_03 AC 419 ms
80,596 KB
testcase_04 AC 413 ms
81,016 KB
testcase_05 AC 232 ms
79,992 KB
testcase_06 AC 371 ms
80,636 KB
testcase_07 AC 245 ms
80,668 KB
testcase_08 AC 226 ms
80,624 KB
testcase_09 AC 113 ms
80,528 KB
testcase_10 AC 220 ms
80,656 KB
testcase_11 AC 367 ms
80,920 KB
testcase_12 AC 321 ms
80,532 KB
testcase_13 AC 215 ms
80,504 KB
testcase_14 AC 334 ms
80,380 KB
testcase_15 AC 217 ms
80,260 KB
testcase_16 AC 320 ms
80,572 KB
testcase_17 AC 366 ms
80,300 KB
testcase_18 AC 378 ms
80,464 KB
testcase_19 AC 92 ms
80,260 KB
testcase_20 AC 302 ms
80,384 KB
testcase_21 AC 103 ms
80,472 KB
testcase_22 AC 133 ms
80,376 KB
testcase_23 AC 351 ms
80,536 KB
testcase_24 AC 387 ms
80,408 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N,M=map(int,input().split())
Z=[0]*(10**5*5+1)
for _ in range(M):
    L,R=map(int,input().split())
    Z[-1-L]+=1
    Z[-R]-=1
now=0
for i in range(N+1,1,-1):
    now+=Z[-i]
    print(now)
0