結果

問題 No.397 NO MORE KADOMATSU
ユーザー qibqib
提出日時 2023-04-19 03:58:49
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 244 bytes
コンパイル時間 241 ms
コンパイル使用メモリ 82,408 KB
実行使用メモリ 77,000 KB
平均クエリ数 38.72
最終ジャッジ日時 2024-04-22 04:51:17
合計ジャッジ時間 4,349 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 62 ms
68,576 KB
testcase_01 WA -
testcase_02 AC 60 ms
68,576 KB
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 AC 65 ms
74,336 KB
testcase_10 WA -
testcase_11 AC 64 ms
74,332 KB
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 AC 77 ms
68,816 KB
testcase_17 AC 62 ms
68,304 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

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

ans = []
for i in range(n):
  min_j = i
  for j in range(i, n):
    if a[j] < a[min_j]:
      min_j = j
  if i != min_j:
    ans.append(f"{i} {min_j}")

print(len(ans))
print(*ans, sep="\n")
0