結果
問題 |
No.1338 Giant Class
|
ユーザー |
![]() |
提出日時 | 2021-01-25 17:16:12 |
言語 | PyPy3 (7.3.15) |
結果 |
RE
|
実行時間 | - |
コード長 | 423 bytes |
コンパイル時間 | 260 ms |
コンパイル使用メモリ | 81,968 KB |
実行使用メモリ | 842,180 KB |
最終ジャッジ日時 | 2024-06-22 09:12:35 |
合計ジャッジ時間 | 6,010 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 11 RE * 1 MLE * 1 -- * 8 |
ソースコード
# coding:UTF-8 import sys MOD = 10 ** 9 + 7 INF = float('inf') H, W, Q = list(map(int, input().split())) # スペース区切り連続数字 YX = [list(map(int, input().split())) for _ in range(Q)] # スペース区切り連続数字(行列) res = H * W zan = [H] * W for y, x in YX: t = y - 1 if zan[x-1] > t: d = zan[x-1] - t zan[x-1] = t res -= d print("{}".format(res))