結果
問題 | No.1338 Giant Class |
ユーザー |
👑 |
提出日時 | 2021-04-11 20:15:36 |
言語 | Lua (LuaJit 2.1.1734355927) |
結果 |
AC
|
実行時間 | 172 ms / 2,000 ms |
コード長 | 316 bytes |
コンパイル時間 | 100 ms |
コンパイル使用メモリ | 6,688 KB |
実行使用メモリ | 10,264 KB |
最終ジャッジ日時 | 2024-06-27 14:45:15 |
合計ジャッジ時間 | 4,339 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 21 |
ソースコード
local h, w, q = io.read("*n", "*n", "*n") local t = {} local ret = 1LL * w * h for iq = 1, q do local y, x = io.read("*n", "*n") if not t[x] then ret = ret - (h - y + 1) t[x] = y elseif y < t[x] then ret = ret - (t[x] - y) t[x] = y end local z = tostring(ret):gsub("LL", "") print(z) end