結果
| 問題 |
No.3018 目隠し宝探し
|
| ユーザー |
|
| 提出日時 | 2025-01-25 14:11:06 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 302 bytes |
| コンパイル時間 | 428 ms |
| コンパイル使用メモリ | 81,792 KB |
| 実行使用メモリ | 81,656 KB |
| 平均クエリ数 | 2.68 |
| 最終ジャッジ日時 | 2025-01-25 23:10:27 |
| 合計ジャッジ時間 | 4,085 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 13 WA * 7 RE * 1 |
ソースコード
H,W=map(int,input().split())
print("?",1,1,flush=1)
d1=int(input())
if d1==0:
print("!",1,1,flush=1)
exit()
print("?",H,W,flush=1)
d2=int(input())
for h in range(1,H+1):
for w in range(1,W+1):
if (h-1)**2+(w-1)**2==d1 and (H-h)**2+(W-w)**2==d2:
print("!",h,w,flush=1)
exit()