結果
問題 | No.693 square1001 and Permutation 2 |
ユーザー |
![]() |
提出日時 | 2018-06-08 22:31:20 |
言語 | Lua (LuaJit 2.1.1734355927) |
結果 |
WA
|
実行時間 | - |
コード長 | 170 bytes |
コンパイル時間 | 57 ms |
コンパイル使用メモリ | 6,816 KB |
実行使用メモリ | 6,944 KB |
最終ジャッジ日時 | 2024-06-30 10:49:20 |
合計ジャッジ時間 | 611 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 6 WA * 3 |
ソースコード
print((function (n, s)local a=n*(n+1)/2local b=0 for e in s:gmatch("%d+") do b=b+tonumber(e) endreturn math.abs(a-b)end)(io.stdin:read("*l"), io.stdin:read("*l")))