結果
| 問題 | No.5 数字のブロック |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2024-12-18 16:25:54 |
| 言語 | Python3 (3.15.2 + numpy 2.5.4 + scipy 1.18.1 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 24 ms / 5,000 ms |
| + 395µs | |
| コード長 | 320 bytes |
| 記録 | |
| コンパイル時間 | 56 ms |
| コンパイル使用メモリ | 14,976 KB |
| 実行使用メモリ | 11,904 KB |
| 最終ジャッジ日時 | 2026-10-04 23:29:30 |
| 合計ジャッジ時間 | 2,658 ms |
|
ジャッジサーバーID (参考情報) |
judge4_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 34 |
ソースコード
inp1 = input()
inp_dust = input()
inp2 = input().split()
seq= []
for s in inp2:
seq.append(int(s))
seq = sorted(seq)
num = int(inp1)
box = 0
count = 0
for s in seq:
box = box + s
count = count + 1
if box == num:
break
elif box >= num:
count = count - 1
break
print(count)