結果
| 問題 | No.2847 Birthday Attack |
| コンテスト | |
| ユーザー |
dp_ijk
|
| 提出日時 | 2024-08-23 23:02:17 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 300 bytes |
| 記録 | |
| コンパイル時間 | 154 ms |
| コンパイル使用メモリ | 84,992 KB |
| 実行使用メモリ | 80,128 KB |
| 最終ジャッジ日時 | 2026-04-03 22:05:31 |
| 合計ジャッジ時間 | 1,428 ms |
|
ジャッジサーバーID (参考情報) |
judge5_1 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | WA * 14 |
ソースコード
X, Y, M = map(int, input().split()) ans = 0 cnt = 0 for r in range(1, (X-1) // 2 + 1): term = X - r*2 assert term >= 0 cnt += term cnt *= Y*2 ans += cnt cnt = 0 for r in range(1, (Y-1) // 2 + 1): term = Y - r*2 assert term >= 0 cnt += term cnt *= X*2 ans += cnt ans %= M print(ans)
dp_ijk