結果

問題 No.617 Nafmo、買い出しに行く
ユーザー motor_radialmotor_radial
提出日時 2019-08-16 19:58:22
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 208 bytes
コンパイル時間 1,033 ms
コンパイル使用メモリ 11,788 KB
実行使用メモリ 10,020 KB
最終ジャッジ日時 2023-10-23 19:56:09
合計ジャッジ時間 1,892 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 27 ms
10,008 KB
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 RE -
testcase_09 AC 28 ms
10,008 KB
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 RE -
testcase_16 AC 28 ms
10,008 KB
testcase_17 RE -
testcase_18 RE -
testcase_19 RE -
testcase_20 AC 28 ms
10,008 KB
testcase_21 AC 28 ms
10,008 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N,K=map(int,input().split())
A=[int(input()) for _ in range(N)]
A.insert(0,0)
ans=[]
for i in range(N-1):
    for j in range(1,N+1):
        if K>=(A[i]+A[j]):
            ans.append(A[i]+A[j])
print(ans[-1])
0