結果
問題 |
No.490 yukiソート
|
ユーザー |
![]() |
提出日時 | 2018-04-01 17:16:15 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
WA
|
実行時間 | - |
コード長 | 495 bytes |
コンパイル時間 | 300 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 17,824 KB |
最終ジャッジ日時 | 2024-06-26 05:42:07 |
合計ジャッジ時間 | 22,219 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | -- * 2 |
other | AC * 10 WA * 4 TLE * 1 -- * 19 |
ソースコード
n = int(input().strip()) a = [int(i) for i in input().strip().split(" ")] for i in range(1, 2*n-3): for q in range(1, n): if a[0] > a[q]: tmp = a[0] a[0] = a[q] a[q] = tmp for p in range(1, n-1): last = i - p if last >= n: last = n for q in range(p+1, last): if a[p] > a[q]: tmp = a[q] a[q] = a[p] a[p] = tmp print(" ".join([str(i) for i in a]))