結果
問題 |
No.2239 Friday
|
ユーザー |
![]() |
提出日時 | 2023-11-06 17:11:18 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 296 bytes |
コンパイル時間 | 145 ms |
コンパイル使用メモリ | 82,444 KB |
実行使用メモリ | 53,384 KB |
最終ジャッジ日時 | 2024-09-25 23:05:05 |
合計ジャッジ時間 | 1,494 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 19 WA * 1 |
ソースコード
a, b = map(int, input().split()) t = min(a, b) * 2 f = a + b - t cnt = min(a, b) if t < f: print(abs(t - f)) else: tmp = abs(t - f) while abs((t - 1) - (f + 1)) < tmp and 0 <= t - 1 and 0 < cnt: cnt -= 1 t, f = t - 1, f + 1 tmp = abs((t) - (f)) print(tmp)