結果

問題 No.5 数字のブロック
ユーザー akitsugu777akitsugu777
提出日時 2019-09-12 11:12:18
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 355 ms / 5,000 ms
コード長 131 bytes
コンパイル時間 67 ms
コンパイル使用メモリ 10,520 KB
実行使用メモリ 9,260 KB
最終ジャッジ日時 2023-09-15 14:11:18
合計ジャッジ時間 4,440 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 14 ms
7,816 KB
testcase_01 AC 15 ms
7,784 KB
testcase_02 AC 15 ms
7,912 KB
testcase_03 AC 156 ms
8,748 KB
testcase_04 AC 101 ms
8,444 KB
testcase_05 AC 231 ms
8,812 KB
testcase_06 AC 110 ms
8,572 KB
testcase_07 AC 80 ms
8,552 KB
testcase_08 AC 134 ms
8,792 KB
testcase_09 AC 31 ms
8,228 KB
testcase_10 AC 269 ms
9,116 KB
testcase_11 AC 76 ms
8,416 KB
testcase_12 AC 160 ms
8,792 KB
testcase_13 AC 224 ms
8,848 KB
testcase_14 AC 14 ms
7,796 KB
testcase_15 AC 15 ms
7,728 KB
testcase_16 AC 242 ms
8,780 KB
testcase_17 AC 323 ms
9,148 KB
testcase_18 AC 286 ms
9,076 KB
testcase_19 AC 355 ms
9,260 KB
testcase_20 AC 15 ms
7,712 KB
testcase_21 AC 15 ms
7,764 KB
testcase_22 AC 15 ms
7,812 KB
testcase_23 AC 14 ms
7,796 KB
testcase_24 AC 14 ms
7,864 KB
testcase_25 AC 16 ms
7,708 KB
testcase_26 AC 14 ms
7,784 KB
testcase_27 AC 15 ms
7,924 KB
testcase_28 AC 15 ms
7,884 KB
testcase_29 AC 98 ms
8,344 KB
testcase_30 AC 37 ms
8,336 KB
testcase_31 AC 15 ms
7,772 KB
testcase_32 AC 15 ms
7,920 KB
testcase_33 AC 15 ms
7,768 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

L = int(input())
N = int(input())
W = sorted(map(int, input().split()))
# print(L, W)

while sum(W) > L:
    W.pop()

print(len(W))
0