結果

問題 No.2154 あさかつの参加人数
ユーザー MasKoaTSMasKoaTS
提出日時 2022-12-09 21:30:32
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 545 ms / 2,000 ms
コード長 901 bytes
コンパイル時間 195 ms
コンパイル使用メモリ 82,332 KB
実行使用メモリ 152,632 KB
最終ジャッジ日時 2024-04-22 20:47:21
合計ジャッジ時間 14,876 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 545 ms
152,064 KB
testcase_01 AC 544 ms
152,592 KB
testcase_02 AC 542 ms
152,632 KB
testcase_03 AC 540 ms
152,172 KB
testcase_04 AC 522 ms
152,448 KB
testcase_05 AC 385 ms
128,896 KB
testcase_06 AC 465 ms
144,256 KB
testcase_07 AC 343 ms
119,552 KB
testcase_08 AC 339 ms
117,120 KB
testcase_09 AC 202 ms
95,616 KB
testcase_10 AC 317 ms
116,224 KB
testcase_11 AC 474 ms
143,612 KB
testcase_12 AC 407 ms
133,376 KB
testcase_13 AC 323 ms
118,272 KB
testcase_14 AC 450 ms
138,624 KB
testcase_15 AC 313 ms
115,072 KB
testcase_16 AC 430 ms
134,656 KB
testcase_17 AC 463 ms
144,512 KB
testcase_18 AC 493 ms
145,536 KB
testcase_19 AC 175 ms
92,032 KB
testcase_20 AC 421 ms
131,840 KB
testcase_21 AC 193 ms
94,080 KB
testcase_22 AC 231 ms
99,456 KB
testcase_23 AC 470 ms
141,184 KB
testcase_24 AC 485 ms
146,560 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import itertools as iter
import collections as coll
import heapq as hq
import bisect as bis
from decimal import Decimal as dec
from functools import cmp_to_key
import math
import sys
#import pypyjit
#pypyjit.set_param('max_unroll_recursion=-1')
sys.setrecursionlimit(10 ** 6)
inp = sys.stdin.readline
input = lambda : inp().rstrip()
getN = lambda : int(inp())
getNs = lambda : map(int, inp().split())
getList = lambda :list(map(int, inp().split()))
getStrs = lambda n : [input() for _ in [0] * n]
def yexit(): print("Yes"); exit(0)
def nexit(): print("No"); exit(0)
pi = 3.141592653589793
mod = 1000000007
MOD = 998244353
INF = 4611686018427387903
dx = [1, 0, -1, 0];	dy = [0, 1, 0, -1]
#di = coll.defaultdict(int)


"""
Main Code
"""

n, m = getNs()
imos = [0] * (n + 1)
for l, r in [getList() for _ in [0]*m]:
	imos[n - l] += 1
	imos[n - r + 1] -= 1
now = 0
for k in imos[:n]:
	now += k
	print(now)
0