結果

問題 No.514 宝探し3
ユーザー kimiyukikimiyuki
提出日時 2017-05-09 18:24:51
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 38 ms / 2,000 ms
コード長 315 bytes
コンパイル時間 70 ms
コンパイル使用メモリ 10,636 KB
実行使用メモリ 24,428 KB
平均クエリ数 2.75
最終ジャッジ日時 2023-09-23 13:59:29
合計ジャッジ時間 1,633 ms
ジャッジサーバーID
(参考情報)
judge13 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 38 ms
24,428 KB
testcase_01 AC 35 ms
23,800 KB
testcase_02 AC 34 ms
24,012 KB
testcase_03 AC 33 ms
24,112 KB
testcase_04 AC 34 ms
24,348 KB
testcase_05 AC 33 ms
23,852 KB
testcase_06 AC 31 ms
23,992 KB
testcase_07 AC 33 ms
23,936 KB
testcase_08 AC 35 ms
24,288 KB
testcase_09 AC 34 ms
24,364 KB
testcase_10 AC 32 ms
24,252 KB
testcase_11 AC 33 ms
23,860 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#!/usr/bin/env python3
import sys
def d(x, y):
    print(x, y)
    sys.stdout.flush()
    result = int(input())
    if result == 0:
        sys.exit(0)
    return result
limit = 1000000000
d1 = d(0, 0)
d2 = d(limit, 0)
x = (+ limit + d1 - d2) // 2
y = (- limit + d1 + d2) // 2
d(x, y)
assert False # already exited
0