結果

問題 No.514 宝探し3
ユーザー yuppe19 😺yuppe19 😺
提出日時 2017-05-21 13:52:23
言語 Python2
(2.7.18)
結果
AC  
実行時間 39 ms / 2,000 ms
コード長 318 bytes
コンパイル時間 46 ms
コンパイル使用メモリ 6,696 KB
実行使用メモリ 24,336 KB
平均クエリ数 2.67
最終ジャッジ日時 2023-09-23 14:08:03
合計ジャッジ時間 1,449 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 38 ms
23,568 KB
testcase_01 AC 37 ms
23,820 KB
testcase_02 AC 39 ms
23,532 KB
testcase_03 AC 35 ms
23,976 KB
testcase_04 AC 34 ms
24,336 KB
testcase_05 AC 35 ms
23,448 KB
testcase_06 AC 33 ms
23,628 KB
testcase_07 AC 35 ms
23,616 KB
testcase_08 AC 35 ms
23,364 KB
testcase_09 AC 34 ms
23,328 KB
testcase_10 AC 35 ms
23,976 KB
testcase_11 AC 35 ms
23,340 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#!/usr/bin/python2
# -*- coding: utf-8 -*-
# †
import sys

def ask(x, y):
    print '{x} {y}'.format(**locals())
    sys.stdout.flush()
    dist = int(raw_input())
    if dist == 0:
        exit(0)
    return dist


dist1 = ask(0, 0)
dist2 = ask(dist1, 0)
assert dist2 % 2 == 0
y = dist2 / 2
x = dist1 - y
ask(x, y)
0