結果

問題 No.257 N言っちゃダメゲーム (3)
ユーザー lllllll88938494lllllll88938494
提出日時 2023-05-09 03:09:26
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 90 ms / 2,000 ms
コード長 266 bytes
コンパイル時間 256 ms
コンパイル使用メモリ 82,424 KB
実行使用メモリ 70,596 KB
平均クエリ数 3.70
最終ジャッジ日時 2024-11-25 17:24:41
合計ジャッジ時間 4,395 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 85 ms
69,216 KB
testcase_01 AC 90 ms
69,140 KB
testcase_02 AC 90 ms
68,608 KB
testcase_03 AC 85 ms
68,868 KB
testcase_04 AC 83 ms
69,440 KB
testcase_05 AC 85 ms
69,804 KB
testcase_06 AC 83 ms
69,332 KB
testcase_07 AC 83 ms
69,972 KB
testcase_08 AC 82 ms
69,244 KB
testcase_09 AC 83 ms
69,992 KB
testcase_10 AC 86 ms
69,420 KB
testcase_11 AC 89 ms
69,168 KB
testcase_12 AC 84 ms
70,048 KB
testcase_13 AC 82 ms
68,408 KB
testcase_14 AC 83 ms
69,128 KB
testcase_15 AC 86 ms
69,624 KB
testcase_16 AC 84 ms
68,956 KB
testcase_17 AC 82 ms
69,028 KB
testcase_18 AC 82 ms
70,596 KB
testcase_19 AC 85 ms
69,788 KB
testcase_20 AC 84 ms
69,000 KB
testcase_21 AC 83 ms
68,956 KB
testcase_22 AC 83 ms
69,168 KB
testcase_23 AC 85 ms
68,700 KB
testcase_24 AC 83 ms
69,464 KB
testcase_25 AC 83 ms
69,432 KB
testcase_26 AC 82 ms
69,768 KB
testcase_27 AC 84 ms
68,420 KB
testcase_28 AC 84 ms
69,044 KB
testcase_29 AC 84 ms
70,244 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n,k = map(int,input().split())
if  (n-1)%(k+1) == 0:
    print(0,flush=True)
    now=int(input())
    if now >= n:
        exit()
else:
    now = 0

while True:
    a=((n-1)-now)%(k+1)
    print(a+now,flush=True)
    now = int(input())
    if now >= n:
        break
0