結果

問題 No.2424 Josouzai
ユーザー pluto77pluto77
提出日時 2023-08-22 10:40:59
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 138 bytes
コンパイル時間 375 ms
コンパイル使用メモリ 10,604 KB
実行使用メモリ 30,028 KB
最終ジャッジ日時 2023-08-22 10:41:08
合計ジャッジ時間 8,655 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 15 ms
7,832 KB
testcase_01 AC 15 ms
7,828 KB
testcase_02 AC 15 ms
7,776 KB
testcase_03 WA -
testcase_04 AC 47 ms
14,776 KB
testcase_05 AC 129 ms
29,944 KB
testcase_06 AC 155 ms
30,028 KB
testcase_07 AC 128 ms
29,808 KB
testcase_08 AC 129 ms
29,996 KB
testcase_09 AC 15 ms
7,916 KB
testcase_10 AC 34 ms
14,796 KB
testcase_11 AC 71 ms
27,568 KB
testcase_12 AC 57 ms
22,496 KB
testcase_13 AC 47 ms
14,796 KB
testcase_14 AC 74 ms
19,872 KB
testcase_15 AC 23 ms
9,712 KB
testcase_16 AC 115 ms
27,016 KB
testcase_17 AC 38 ms
12,812 KB
testcase_18 AC 43 ms
13,764 KB
testcase_19 AC 65 ms
18,072 KB
testcase_20 AC 118 ms
27,336 KB
testcase_21 AC 89 ms
22,612 KB
testcase_22 AC 46 ms
14,332 KB
testcase_23 AC 54 ms
15,816 KB
testcase_24 AC 32 ms
11,528 KB
testcase_25 AC 123 ms
28,400 KB
testcase_26 AC 89 ms
22,652 KB
testcase_27 AC 127 ms
29,300 KB
testcase_28 AC 108 ms
26,096 KB
testcase_29 AC 98 ms
24,064 KB
testcase_30 AC 33 ms
11,812 KB
testcase_31 AC 63 ms
17,388 KB
testcase_32 AC 125 ms
28,828 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n,k=map(int,input().split())
a=list(map(int,input().split()))
a.sort()
s=0
for i in range(n):
 s+=a[i]
 if s>k:
  break
print(i,k-s+a[i])
0