結果
問題 |
No.2124 Guess the Permutation
|
ユーザー |
|
提出日時 | 2022-11-18 21:33:16 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 306 bytes |
コンパイル時間 | 151 ms |
コンパイル使用メモリ | 81,792 KB |
実行使用メモリ | 84,312 KB |
平均クエリ数 | 374.60 |
最終ジャッジ日時 | 2024-09-20 01:57:54 |
合計ジャッジ時間 | 1,773 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | WA * 1 |
other | WA * 9 |
ソースコード
N = int(input()) all_sum = (N * (1 + N)) // 2 P = [] ever_sum = 0 for l in range(2, N): print(f"? {l} {N}") kukanwa = int(input()) P.append(all_sum - kukanwa - ever_sum) ever_sum += P[-1] print(f"? {1} {N - 1}") kukanwa = int(input()) P.append(all_sum - kukanwa) print("!" , *P)