結果

問題 No.521 Cheeses and a Mousetrap(チーズとネズミ捕り)
ユーザー toyuzukotoyuzuko
提出日時 2020-10-17 22:04:58
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 140 bytes
コンパイル時間 377 ms
コンパイル使用メモリ 81,792 KB
実行使用メモリ 51,840 KB
最終ジャッジ日時 2024-07-21 03:10:34
合計ジャッジ時間 2,486 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 14 WA * 14
権限があれば一括ダウンロードができます

ソースコード

diff #

N, K = map(int, input().split())
if K == 0 or K > N:
    print(0)
elif N % 2 == 1 and (N + 1) // 2 == K:
    print(N - 1)
else:
    print(N)
0