結果

問題 No.2210 equence Squence Seuence
ユーザー flygonflygon
提出日時 2023-02-10 23:13:03
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 370 bytes
コンパイル時間 370 ms
コンパイル使用メモリ 87,204 KB
実行使用メモリ 114,672 KB
最終ジャッジ日時 2023-09-22 00:17:14
合計ジャッジ時間 5,589 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 69 ms
71,328 KB
testcase_01 AC 70 ms
71,352 KB
testcase_02 AC 74 ms
71,416 KB
testcase_03 AC 99 ms
85,660 KB
testcase_04 WA -
testcase_05 AC 113 ms
94,908 KB
testcase_06 AC 108 ms
90,928 KB
testcase_07 AC 144 ms
112,688 KB
testcase_08 AC 71 ms
71,396 KB
testcase_09 AC 69 ms
71,448 KB
testcase_10 AC 68 ms
71,444 KB
testcase_11 WA -
testcase_12 AC 69 ms
71,260 KB
testcase_13 AC 160 ms
107,456 KB
testcase_14 WA -
testcase_15 WA -
testcase_16 AC 161 ms
107,616 KB
testcase_17 WA -
testcase_18 WA -
testcase_19 AC 71 ms
71,260 KB
testcase_20 AC 72 ms
71,044 KB
testcase_21 AC 72 ms
71,324 KB
testcase_22 WA -
testcase_23 AC 145 ms
114,672 KB
testcase_24 AC 130 ms
106,368 KB
testcase_25 AC 135 ms
110,440 KB
testcase_26 AC 150 ms
106,980 KB
testcase_27 AC 102 ms
87,592 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

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

ans = -1

for i in range(n-1):
  x,y = a[i], a[i+1]
  if n-i < k:
    k = n-i
  if k == 1 and y < x:
    ans = i
  if y < x:
    k -= 1
  if x < y and k == n-i:
    ans = i
  if ans != -1:
    break
  
if ans == -1:
  ans = n-1

b = []
for i in range(n):
  if i != ans:
    b.append(a[i])
  
print(*b)

0