結果

問題 No.490 yukiソート
ユーザー titiatitia
提出日時 2023-06-14 05:53:07
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 136 ms / 2,000 ms
コード長 246 bytes
コンパイル時間 283 ms
コンパイル使用メモリ 87,112 KB
実行使用メモリ 77,280 KB
最終ジャッジ日時 2023-09-04 20:58:30
合計ジャッジ時間 5,196 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 76 ms
71,452 KB
testcase_01 AC 73 ms
71,496 KB
testcase_02 AC 72 ms
71,276 KB
testcase_03 AC 72 ms
71,520 KB
testcase_04 AC 87 ms
76,320 KB
testcase_05 AC 88 ms
76,504 KB
testcase_06 AC 86 ms
76,220 KB
testcase_07 AC 87 ms
76,460 KB
testcase_08 AC 86 ms
76,100 KB
testcase_09 AC 85 ms
76,464 KB
testcase_10 AC 86 ms
76,596 KB
testcase_11 AC 87 ms
76,188 KB
testcase_12 AC 86 ms
76,312 KB
testcase_13 AC 85 ms
76,468 KB
testcase_14 AC 135 ms
77,068 KB
testcase_15 AC 134 ms
77,012 KB
testcase_16 AC 135 ms
76,788 KB
testcase_17 AC 135 ms
77,120 KB
testcase_18 AC 134 ms
77,280 KB
testcase_19 AC 133 ms
76,900 KB
testcase_20 AC 133 ms
76,956 KB
testcase_21 AC 136 ms
76,956 KB
testcase_22 AC 134 ms
77,108 KB
testcase_23 AC 134 ms
76,908 KB
testcase_24 AC 73 ms
71,452 KB
testcase_25 AC 73 ms
71,396 KB
testcase_26 AC 73 ms
71,216 KB
testcase_27 AC 72 ms
71,240 KB
testcase_28 AC 72 ms
71,244 KB
testcase_29 AC 74 ms
71,244 KB
testcase_30 AC 75 ms
71,344 KB
testcase_31 AC 72 ms
71,084 KB
testcase_32 AC 73 ms
71,604 KB
testcase_33 AC 74 ms
71,088 KB
testcase_34 AC 72 ms
71,448 KB
testcase_35 AC 71 ms
71,544 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = sys.stdin.readline

n=int(input())
A=list(map(int,input().split()))

for i in range(1,2*n-3):
    for p in range(n):
        q=i-p

        if 0<=p<q<=n-1:
            if A[p]>A[q]:
                A[p],A[q]=A[q],A[p]
print(*A)
0