結果

問題 No.1438 Broken Drawers
ユーザー googol_S0googol_S0
提出日時 2021-03-26 21:53:17
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 613 ms / 2,000 ms
コード長 170 bytes
コンパイル時間 409 ms
コンパイル使用メモリ 86,888 KB
実行使用メモリ 109,988 KB
最終ジャッジ日時 2023-08-19 08:08:10
合計ジャッジ時間 11,035 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 64 ms
71,436 KB
testcase_01 AC 65 ms
71,436 KB
testcase_02 AC 65 ms
71,256 KB
testcase_03 AC 68 ms
71,160 KB
testcase_04 AC 63 ms
71,396 KB
testcase_05 AC 64 ms
71,164 KB
testcase_06 AC 134 ms
109,616 KB
testcase_07 AC 134 ms
109,548 KB
testcase_08 AC 64 ms
71,300 KB
testcase_09 AC 63 ms
71,224 KB
testcase_10 AC 64 ms
71,500 KB
testcase_11 AC 85 ms
76,508 KB
testcase_12 AC 234 ms
93,492 KB
testcase_13 AC 346 ms
101,020 KB
testcase_14 AC 174 ms
87,528 KB
testcase_15 AC 563 ms
106,948 KB
testcase_16 AC 551 ms
107,300 KB
testcase_17 AC 613 ms
109,816 KB
testcase_18 AC 567 ms
109,780 KB
testcase_19 AC 557 ms
109,660 KB
testcase_20 AC 594 ms
109,928 KB
testcase_21 AC 557 ms
109,984 KB
testcase_22 AC 562 ms
109,988 KB
testcase_23 AC 585 ms
109,804 KB
testcase_24 AC 587 ms
109,440 KB
testcase_25 AC 595 ms
109,464 KB
testcase_26 AC 598 ms
109,464 KB
testcase_27 AC 597 ms
109,720 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N=int(input())
A=list(map(int,input().split()))
X=[[A[i],i] for i in range(N)]
X.sort()
Y=[0]*(N+1)
for i in range(N):
  if Y[X[i][1]+1]^1:
    Y[X[i][1]]=1
print(sum(Y))
0