結果
問題 |
No.2154 あさかつの参加人数
|
ユーザー |
|
提出日時 | 2022-12-11 23:42:11 |
言語 | PyPy3 (7.3.15) |
結果 |
RE
|
実行時間 | - |
コード長 | 414 bytes |
コンパイル時間 | 195 ms |
コンパイル使用メモリ | 82,176 KB |
実行使用メモリ | 81,920 KB |
最終ジャッジ日時 | 2024-10-15 18:44:33 |
合計ジャッジ時間 | 12,882 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 15 RE * 10 |
ソースコード
import sys if sys.platform =='ios': import clipboard a=clipboard.get() a = a.split('\n') text = '\n'.join(a) with open('input_file.txt','w') as f: f.write(text) sys.stdin = open('input_file.txt') n,m = map(int,input().split()) dp = [0]*n for i in range(m): l,r = map(int,input().split()) dp[l] -= 1 dp[r-1] += 1 for i in range(1,n): dp[i] = dp[i]+dp[i-1] for i in range(n-1,-1,-1): print(dp[i])