結果
| 問題 |
No.72 そろばん Med
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2018-12-29 19:35:38 |
| 言語 | Lua (LuaJit 2.1.1734355927) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 5,000 ms |
| コード長 | 185 bytes |
| コンパイル時間 | 138 ms |
| コンパイル使用メモリ | 5,120 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-10-01 21:16:23 |
| 合計ジャッジ時間 | 954 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 24 |
ソースコード
print((function (f)
return tostring(f(1000007ULL,io.stdin:read("*n")+0ULL)):sub(1,-4)
end)(function (m, n)
return n%2==0 and (((n/2+2)%m)*(n/2%m))%m or (((n/2+3)%m)*(n/2%m)+1)%m
end))