結果

問題 No.365 ジェンガソート
ユーザー m4tsum4tsu
提出日時 2018-06-16 20:26:52
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 94 ms / 2,000 ms
コード長 374 bytes
コンパイル時間 68 ms
コンパイル使用メモリ 10,724 KB
実行使用メモリ 19,716 KB
最終ジャッジ日時 2023-09-13 06:15:48
合計ジャッジ時間 3,292 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 14 ms
7,808 KB
testcase_01 AC 14 ms
7,740 KB
testcase_02 AC 14 ms
7,880 KB
testcase_03 AC 15 ms
7,780 KB
testcase_04 AC 14 ms
7,776 KB
testcase_05 AC 14 ms
7,756 KB
testcase_06 AC 14 ms
7,856 KB
testcase_07 AC 14 ms
7,804 KB
testcase_08 AC 15 ms
7,736 KB
testcase_09 AC 14 ms
7,820 KB
testcase_10 AC 14 ms
7,760 KB
testcase_11 AC 15 ms
7,844 KB
testcase_12 AC 14 ms
7,888 KB
testcase_13 AC 14 ms
7,716 KB
testcase_14 AC 15 ms
7,760 KB
testcase_15 AC 14 ms
7,852 KB
testcase_16 AC 73 ms
16,936 KB
testcase_17 AC 76 ms
18,832 KB
testcase_18 AC 20 ms
9,024 KB
testcase_19 AC 68 ms
18,824 KB
testcase_20 AC 29 ms
11,660 KB
testcase_21 AC 32 ms
10,548 KB
testcase_22 AC 73 ms
16,228 KB
testcase_23 AC 49 ms
13,128 KB
testcase_24 AC 73 ms
15,796 KB
testcase_25 AC 32 ms
10,320 KB
testcase_26 AC 58 ms
14,224 KB
testcase_27 AC 91 ms
19,424 KB
testcase_28 AC 59 ms
14,688 KB
testcase_29 AC 83 ms
17,720 KB
testcase_30 AC 61 ms
14,728 KB
testcase_31 AC 35 ms
11,104 KB
testcase_32 AC 35 ms
10,956 KB
testcase_33 AC 89 ms
19,164 KB
testcase_34 AC 27 ms
9,980 KB
testcase_35 AC 71 ms
16,372 KB
testcase_36 AC 62 ms
19,592 KB
testcase_37 AC 93 ms
19,716 KB
testcase_38 AC 94 ms
19,672 KB
testcase_39 AC 77 ms
19,588 KB
testcase_40 AC 77 ms
19,620 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
genga = list(map(int, input().split()))
#print(genga)

b = 0
c = 0

#その数の前にそれより大きな数があるもののうちの最大c
for a in genga:
    if a < b:
        c = max(c, a)
    else:
        b = a

count = 0

#Cより小さいものは結局1回動かす必要がある
for a in genga:
    if a <= c:
        count += 1
print(count)
0