結果
| 問題 |
No.397 NO MORE KADOMATSU
|
| コンテスト | |
| ユーザー |
vorg101
|
| 提出日時 | 2016-07-15 23:04:27 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
AC
|
| 実行時間 | 80 ms / 2,000 ms |
| コード長 | 337 bytes |
| コンパイル時間 | 278 ms |
| コンパイル使用メモリ | 12,672 KB |
| 実行使用メモリ | 27,864 KB |
| 平均クエリ数 | 936.56 |
| 最終ジャッジ日時 | 2024-07-17 00:06:14 |
| 合計ジャッジ時間 | 2,693 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 18 |
ソースコード
N = int(input())
a = [int(t) for t in input().split(' ')]
query = []
m = 0
cnt = -1
while cnt != 0:
cnt = 0
for i in range(N-1):
if a[i] > a[i+1]:
a[i], a[i+1] = a[i+1], a[i]
query.append((i, i+1))
cnt += 1
m += 1
print(m)
for q in query:
print(q[0], q[1])
d = input()
vorg101