結果
問題 | No.2502 Optimization in the Dark |
ユーザー |
![]() |
提出日時 | 2023-10-14 14:25:52 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 437 bytes |
コンパイル時間 | 410 ms |
コンパイル使用メモリ | 81,664 KB |
実行使用メモリ | 69,856 KB |
平均クエリ数 | 4.00 |
最終ジャッジ日時 | 2024-09-16 09:03:03 |
合計ジャッジ時間 | 5,940 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 4 WA * 39 |
ソースコード
n = int(input()) X = [0] * 3 def ansop(i): ans = [] for j in range(3): ans.append(i % 3 + 1) ans.append((i + 1) % 3 + 1) i -= 2 ans = ans * n print("!", *ans) exit() for i in range(3): print("?", i + 1, 1, (i + 1) % 3 + 1, 1) if input() == "Yes": X[i] = 1 if X.count(0) == 3: ansop(0) elif X.count(0) == 1: ansop((X.index(0) + 2) % 3) else: ansop(X.index(1) % 3)