結果
| 問題 |
No.5 数字のブロック
|
| コンテスト | |
| ユーザー |
nasubi24
|
| 提出日時 | 2020-11-02 18:19:20 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 193 bytes |
| コンパイル時間 | 282 ms |
| コンパイル使用メモリ | 12,544 KB |
| 実行使用メモリ | 11,776 KB |
| 最終ジャッジ日時 | 2024-07-22 06:28:18 |
| 合計ジャッジ時間 | 2,362 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 4 WA * 30 |
ソースコード
n=int(input())
l=int(input())
a=list(map(int,input().split()))
a.sort()
ans=-1
cnt=0
for i in range(n):
cnt+=a[i]
if cnt>l:
ans=i
break
if ans==-1:
ans=n
print(ans)
nasubi24