結果

問題 No.490 yukiソート
コンテスト
ユーザー Navier_Boltzmann
提出日時 2024-01-06 20:03:17
言語 PyPy3
(7.3.17)
コンパイル:
pypy3 -mpy_compile _filename_
実行:
pypy3 _filename_
結果
AC  
実行時間 70 ms / 2,000 ms
コード長 429 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 132 ms
コンパイル使用メモリ 85,632 KB
実行使用メモリ 70,784 KB
最終ジャッジ日時 2026-04-14 13:17:58
合計ジャッジ時間 3,380 ms
ジャッジサーバーID
(参考情報)
judge1_1 / judge2_1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 34
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

from collections import *
from itertools import *
from functools import *
from heapq import *
import sys,math
input = sys.stdin.readline

N = int(input())
A = list(map(int,input().split()))
for i in range(1,2*N-3):

    for j in range(i):
        if j>=N:
            break
        if i-j>=N:
            continue
        if i-j<=j:
            continue
        if (A[j]>A[i-j]):
            A[j],A[i-j] = A[i-j],A[j]
print(*A)

0