結果

問題 No.2150 Site Supporter
ユーザー ohanaohana
提出日時 2023-11-17 16:22:12
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 103 ms / 2,000 ms
コード長 180 bytes
コンパイル時間 247 ms
コンパイル使用メモリ 81,700 KB
実行使用メモリ 106,916 KB
最終ジャッジ日時 2023-11-17 16:22:17
合計ジャッジ時間 4,228 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 34 ms
53,332 KB
testcase_01 AC 35 ms
53,332 KB
testcase_02 AC 35 ms
53,332 KB
testcase_03 AC 35 ms
53,332 KB
testcase_04 AC 35 ms
53,332 KB
testcase_05 AC 35 ms
53,332 KB
testcase_06 AC 34 ms
53,332 KB
testcase_07 AC 35 ms
53,332 KB
testcase_08 AC 53 ms
77,692 KB
testcase_09 AC 100 ms
103,684 KB
testcase_10 AC 73 ms
88,288 KB
testcase_11 AC 91 ms
100,580 KB
testcase_12 AC 64 ms
83,804 KB
testcase_13 AC 58 ms
79,016 KB
testcase_14 AC 35 ms
53,332 KB
testcase_15 AC 35 ms
53,332 KB
testcase_16 AC 35 ms
53,332 KB
testcase_17 AC 103 ms
106,916 KB
testcase_18 AC 67 ms
85,168 KB
testcase_19 AC 53 ms
76,812 KB
testcase_20 AC 81 ms
94,752 KB
testcase_21 AC 49 ms
70,476 KB
testcase_22 AC 99 ms
103,860 KB
testcase_23 AC 35 ms
53,332 KB
testcase_24 AC 35 ms
53,332 KB
testcase_25 AC 35 ms
53,332 KB
testcase_26 AC 35 ms
53,332 KB
testcase_27 AC 75 ms
90,420 KB
testcase_28 AC 98 ms
90,220 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n, k, x = map(int, input().split())

A = list(map(int, input().split()))


dp = [0, float("inf")]

for a in A:
    dp = [min(dp) + a, min(dp[0] + k + x, dp[1] + k)]
print(min(dp))
0