結果

問題 No.490 yukiソート
ユーザー kiricreamcheesekiricreamcheese
提出日時 2017-03-10 23:07:17
言語 Python2
(2.7.18)
結果
AC  
実行時間 1,530 ms / 2,000 ms
コード長 334 bytes
コンパイル時間 587 ms
コンパイル使用メモリ 6,632 KB
実行使用メモリ 6,452 KB
最終ジャッジ日時 2023-09-06 15:57:40
合計ジャッジ時間 17,205 ms
ジャッジサーバーID
(参考情報)
judge11 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 11 ms
6,088 KB
testcase_01 AC 12 ms
6,044 KB
testcase_02 AC 12 ms
5,964 KB
testcase_03 AC 13 ms
5,932 KB
testcase_04 AC 45 ms
6,120 KB
testcase_05 AC 45 ms
6,092 KB
testcase_06 AC 45 ms
6,128 KB
testcase_07 AC 45 ms
6,120 KB
testcase_08 AC 46 ms
6,132 KB
testcase_09 AC 45 ms
6,032 KB
testcase_10 AC 45 ms
6,084 KB
testcase_11 AC 46 ms
6,128 KB
testcase_12 AC 45 ms
6,000 KB
testcase_13 AC 45 ms
6,096 KB
testcase_14 AC 1,507 ms
6,312 KB
testcase_15 AC 1,530 ms
6,320 KB
testcase_16 AC 1,512 ms
6,404 KB
testcase_17 AC 1,528 ms
6,396 KB
testcase_18 AC 1,504 ms
6,240 KB
testcase_19 AC 1,524 ms
6,248 KB
testcase_20 AC 1,512 ms
6,452 KB
testcase_21 AC 1,499 ms
6,312 KB
testcase_22 AC 1,506 ms
6,404 KB
testcase_23 AC 1,509 ms
6,412 KB
testcase_24 AC 11 ms
6,076 KB
testcase_25 AC 11 ms
6,128 KB
testcase_26 AC 11 ms
6,024 KB
testcase_27 AC 11 ms
6,036 KB
testcase_28 AC 11 ms
6,116 KB
testcase_29 AC 12 ms
6,032 KB
testcase_30 AC 12 ms
6,008 KB
testcase_31 AC 12 ms
6,008 KB
testcase_32 AC 12 ms
5,936 KB
testcase_33 AC 12 ms
6,092 KB
testcase_34 AC 12 ms
6,084 KB
testcase_35 AC 12 ms
5,968 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#!/usr/bin/env python

n=input()
a_list=map(int,raw_input().split(" "))
buf=0

for i in range(1,2*n-3):
    for p in range(n-1):
        q=i-p
        if p<q and q<=n-1:
            if a_list[p]>a_list[q]:
                buf=a_list[p]
                a_list[p]=a_list[q]
                a_list[q]=buf

print " ".join(map(str,a_list))
0