結果

問題 No.513 宝探し2
ユーザー GrayCoderGrayCoder
提出日時 2017-09-03 11:43:28
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
RE  
実行時間 -
コード長 376 bytes
コンパイル時間 93 ms
コンパイル使用メモリ 10,692 KB
実行使用メモリ 24,516 KB
平均クエリ数 78.42
最終ジャッジ日時 2023-09-23 14:30:48
合計ジャッジ時間 2,869 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 RE -
testcase_01 RE -
testcase_02 RE -
testcase_03 RE -
testcase_04 RE -
testcase_05 AC 37 ms
23,640 KB
testcase_06 RE -
testcase_07 RE -
testcase_08 AC 36 ms
24,264 KB
testcase_09 RE -
testcase_10 RE -
testcase_11 AC 37 ms
23,792 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

def main():
    xmin = 0
    xmax = 100000

    print(xmax // 2 + 1, 0)
    y = int(input())
    while True:
        x = xmin + (xmax - xmin) // 2
        print(x, 0)
        ret = int(input())

        if y < ret:
            xmin = x
        else:
            xmax = x
        y = min(y, ret)

        if ret == 0 or xmin == xmax:
            break

    print(x, y)

main()
0