結果

問題 No.2357 Guess the Function
ユーザー 2000 Ekiben2000 Ekiben
提出日時 2023-06-23 21:21:51
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 208 bytes
コンパイル時間 1,989 ms
コンパイル使用メモリ 81,984 KB
実行使用メモリ 70,696 KB
平均クエリ数 3.00
最終ジャッジ日時 2024-07-01 00:59:38
合計ジャッジ時間 1,984 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

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

ソースコード

diff #

print("? 1", flush=True)
y1 = int(input())
print("? 2", flush=True)
y2 = int(input())

if y1 == y2:
    A = 0
    B = y1 + 1
else:
    A = (y2 - y1) % (y2 + 1)
    B = y2 + 1

print(f"! {A} {B}", flush=True)
0