結果
| 問題 | No.3726 Flawless Flow |
| コンテスト | |
| ユーザー |
sig
|
| 提出日時 | 2026-10-15 04:22:59 |
| 言語 | PyPy3 (8.0.0 + ACL) |
| 結果 |
RE
不安定
|
| 実行時間 | - |
| コード長 | 428 bytes |
| 記録 | |
| コンパイル時間 | 786 ms |
| コンパイル使用メモリ | 64,500 KB |
| 実行使用メモリ | 62,732 KB |
| 最終ジャッジ日時 | 2026-10-15 04:23:08 |
| 合計ジャッジ時間 | 7,405 ms |
|
ジャッジサーバーID (参考情報) |
judge5_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 43 RE * 16 |
ソースコード
n = int(input()) a = list(map(int, input().split())) b = list(map(int, input().split())) ind = [0]*(n+1) for i in range(n): ind[b[i]] = i ans = [] ans.append(a[:]) for i in range(n): can = True if i%2: for j in range(1,n-1,2): if ind[a[j]] > ind[a[j+1]]: a[j],a[j+1] = a[j+1],a[j] else: for j in range(0,n,2): if ind[a[j]] > ind[a[j+1]]: a[j],a[j+1] = a[j+1],a[j] ans.append(a[:]) for i in ans: print(*i)
sig