結果

問題 No.1187 皇帝ペンギン
ユーザー 👑 rin204rin204
提出日時 2022-01-18 22:17:15
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 312 bytes
コンパイル時間 211 ms
コンパイル使用メモリ 82,264 KB
実行使用メモリ 70,824 KB
平均クエリ数 16.26
最終ジャッジ日時 2024-11-23 13:32:27
合計ジャッジ時間 7,831 ms
ジャッジサーバーID
(参考情報)
judge2 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 64 ms
69,056 KB
testcase_01 AC 63 ms
68,680 KB
testcase_02 AC 63 ms
68,296 KB
testcase_03 WA -
testcase_04 AC 64 ms
68,424 KB
testcase_05 AC 64 ms
68,552 KB
testcase_06 AC 64 ms
68,296 KB
testcase_07 AC 64 ms
69,064 KB
testcase_08 AC 63 ms
68,424 KB
testcase_09 AC 64 ms
68,168 KB
testcase_10 AC 63 ms
68,808 KB
testcase_11 WA -
testcase_12 AC 62 ms
68,168 KB
testcase_13 AC 64 ms
68,424 KB
testcase_14 AC 64 ms
68,456 KB
testcase_15 AC 63 ms
68,680 KB
testcase_16 AC 62 ms
68,680 KB
testcase_17 AC 64 ms
68,640 KB
testcase_18 AC 64 ms
68,680 KB
testcase_19 AC 63 ms
68,680 KB
testcase_20 AC 63 ms
69,064 KB
testcase_21 AC 63 ms
68,552 KB
testcase_22 AC 63 ms
68,424 KB
testcase_23 AC 64 ms
68,168 KB
testcase_24 AC 64 ms
68,552 KB
testcase_25 AC 63 ms
68,168 KB
testcase_26 AC 64 ms
67,784 KB
testcase_27 AC 64 ms
68,168 KB
testcase_28 AC 65 ms
68,680 KB
testcase_29 AC 64 ms
68,936 KB
testcase_30 AC 64 ms
68,336 KB
testcase_31 AC 63 ms
68,668 KB
testcase_32 AC 65 ms
68,432 KB
testcase_33 AC 65 ms
68,432 KB
testcase_34 AC 65 ms
68,304 KB
testcase_35 AC 64 ms
68,176 KB
testcase_36 AC 65 ms
69,192 KB
testcase_37 AC 65 ms
68,816 KB
testcase_38 AC 63 ms
69,072 KB
testcase_39 AC 63 ms
68,176 KB
testcase_40 AC 64 ms
68,432 KB
testcase_41 AC 65 ms
68,608 KB
testcase_42 AC 63 ms
68,440 KB
testcase_43 AC 63 ms
68,696 KB
testcase_44 AC 63 ms
68,440 KB
testcase_45 AC 64 ms
68,696 KB
testcase_46 AC 63 ms
69,080 KB
testcase_47 WA -
testcase_48 WA -
testcase_49 WA -
testcase_50 WA -
testcase_51 WA -
testcase_52 AC 64 ms
68,560 KB
testcase_53 AC 64 ms
68,560 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

l = 0
r = 10 ** 3

def ask(x):
    print(f"? {x}", flush = True)
    return input()

while r - l > 1:
    mid = (l + r) // 2
    x = ask(mid)
    if x == "safe":
        l = mid
    else:
        x = ask(mid)
        if x == "safe":
            l = mid + 1
        else:
            r = mid
    

print(f"! {l}")
0