結果
| 問題 | No.1338 Giant Class |
| コンテスト | |
| ユーザー |
lie_of_lillie
|
| 提出日時 | 2021-06-02 20:55:43 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 232 ms / 2,000 ms |
| コード長 | 316 bytes |
| 記録 | |
| コンパイル時間 | 182 ms |
| コンパイル使用メモリ | 85,504 KB |
| 実行使用メモリ | 91,440 KB |
| 最終ジャッジ日時 | 2026-05-10 13:42:00 |
| 合計ジャッジ時間 | 5,940 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 21 |
ソースコード
import collections
H,W,Q=map(int, input().split())
max_s = H*W
rank = collections.defaultdict(lambda :H)
for _ in range(Q):
y,x=map(int,input().split())
x-=1; y-=1
if y < rank[x]:
delta = rank[x] - y
max_s -= delta
print(max_s)
rank[x] = y
else:
print(max_s)
lie_of_lillie