結果
| 問題 |
No.2732 Similar Permutations
|
| コンテスト | |
| ユーザー |
kusirakusira
|
| 提出日時 | 2024-04-05 18:07:29 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 316 bytes |
| コンパイル時間 | 341 ms |
| コンパイル使用メモリ | 82,304 KB |
| 実行使用メモリ | 106,752 KB |
| 最終ジャッジ日時 | 2024-10-01 01:24:20 |
| 合計ジャッジ時間 | 20,681 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 40 RE * 61 |
ソースコード
import itertools
n = int(input())
A = list(map(int, input().split()))
s = max(n-10,0)
t = n-s
dic = {}
for P in itertools.permutations(range(s+1,s+t+1)):
y = 0
for i in range(s, s+t):
y ^= P[i]+A[i]
if(y in dic):
print(*dic[y])
print(*P)
exit()
dic[y] = P
print(-1)
kusirakusira