結果

問題 No.2154 あさかつの参加人数
ユーザー titiatitia
提出日時 2022-12-09 21:25:55
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 1,017 ms / 2,000 ms
コード長 242 bytes
コンパイル時間 86 ms
コンパイル使用メモリ 10,476 KB
実行使用メモリ 27,756 KB
最終ジャッジ日時 2023-08-04 21:48:57
合計ジャッジ時間 21,593 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 1,017 ms
27,660 KB
testcase_01 AC 985 ms
27,588 KB
testcase_02 AC 998 ms
27,756 KB
testcase_03 AC 1,000 ms
27,596 KB
testcase_04 AC 1,005 ms
27,700 KB
testcase_05 AC 428 ms
8,276 KB
testcase_06 AC 710 ms
16,416 KB
testcase_07 AC 512 ms
20,648 KB
testcase_08 AC 545 ms
22,372 KB
testcase_09 AC 249 ms
18,140 KB
testcase_10 AC 486 ms
19,416 KB
testcase_11 AC 860 ms
25,484 KB
testcase_12 AC 674 ms
19,532 KB
testcase_13 AC 373 ms
12,260 KB
testcase_14 AC 699 ms
18,780 KB
testcase_15 AC 520 ms
21,896 KB
testcase_16 AC 702 ms
21,012 KB
testcase_17 AC 757 ms
18,444 KB
testcase_18 AC 881 ms
22,116 KB
testcase_19 AC 85 ms
9,884 KB
testcase_20 AC 715 ms
22,896 KB
testcase_21 AC 216 ms
17,136 KB
testcase_22 AC 429 ms
26,012 KB
testcase_23 AC 814 ms
22,624 KB
testcase_24 AC 918 ms
25,172 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = sys.stdin.readline

N,M=map(int,input().split())

S=[0]*(N+5)

for i in range(M):
    l,r=map(int,input().split())
    S[r]+=1
    S[l+1]-=1

for i in range(1,N+5):
    S[i]+=S[i-1]

for i in range(N,0,-1):
    print(S[i])
0