結果

問題 No.1338 Giant Class
ユーザー rin204
提出日時 2022-01-18 18:46:30
言語 PyPy3
(7.3.15)
結果
RE  
実行時間 -
コード長 222 bytes
コンパイル時間 641 ms
コンパイル使用メモリ 82,552 KB
実行使用メモリ 847,760 KB
最終ジャッジ日時 2024-11-23 13:27:12
合計ジャッジ時間 9,510 ms
ジャッジサーバーID
(参考情報)
judge3 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 11 RE * 7 MLE * 3
権限があれば一括ダウンロードができます

ソースコード

diff #

h, w, q = map(int, input().split())

min_ = [h + 1] * w
ans = h * w
for _ in range(q):
    y, x = map(int, input().split())
    x -= 1
    if y < min_[x]:
        ans -= min_[x] - y
        min_[x] = y
    print(ans)
    
0