結果

問題 No.490 yukiソート
ユーザー 双六双六
提出日時 2020-08-19 02:47:27
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 448 bytes
コンパイル時間 157 ms
コンパイル使用メモリ 82,408 KB
実行使用メモリ 70,004 KB
最終ジャッジ日時 2024-04-20 08:08:44
合計ジャッジ時間 3,536 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 41 ms
53,504 KB
testcase_01 WA -
testcase_02 AC 45 ms
53,888 KB
testcase_03 AC 41 ms
53,376 KB
testcase_04 AC 53 ms
63,104 KB
testcase_05 AC 52 ms
62,592 KB
testcase_06 AC 53 ms
62,592 KB
testcase_07 AC 51 ms
62,592 KB
testcase_08 AC 52 ms
63,104 KB
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 WA -
testcase_20 WA -
testcase_21 WA -
testcase_22 WA -
testcase_23 WA -
testcase_24 AC 42 ms
53,760 KB
testcase_25 AC 41 ms
54,016 KB
testcase_26 AC 42 ms
53,376 KB
testcase_27 AC 40 ms
53,376 KB
testcase_28 AC 40 ms
53,376 KB
testcase_29 AC 41 ms
53,376 KB
testcase_30 AC 41 ms
53,632 KB
testcase_31 WA -
testcase_32 WA -
testcase_33 WA -
testcase_34 WA -
testcase_35 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

# import sys; input = sys.stdin.buffer.readline
# sys.setrecursionlimit(10**7)
from collections import defaultdict
con = 10 ** 9 + 7; INF = float("inf")

def getlist():
	return list(map(int, input().split()))

#処理内容
def main():
	N = int(input())
	A = getlist()
	for i in range(1, 2 * N - 2):
		for p in range(N):
			q = i - p
			if p < q <= N - 1 and A[p] > A[q]:
				A[p], A[q] = A[q], A[p]

	print(*A)


if __name__ == '__main__':
	main()
0