結果

問題 No.1325 Subsequence Score
ユーザー flippergoflippergo
提出日時 2020-12-31 00:12:26
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 276 bytes
コンパイル時間 475 ms
コンパイル使用メモリ 82,816 KB
実行使用メモリ 154,172 KB
最終ジャッジ日時 2024-04-17 00:33:37
合計ジャッジ時間 4,140 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 41 ms
52,352 KB
testcase_01 AC 36 ms
51,840 KB
testcase_02 AC 36 ms
51,584 KB
testcase_03 AC 41 ms
59,392 KB
testcase_04 AC 37 ms
52,480 KB
testcase_05 AC 42 ms
59,520 KB
testcase_06 AC 38 ms
52,224 KB
testcase_07 AC 42 ms
59,904 KB
testcase_08 AC 36 ms
51,840 KB
testcase_09 AC 37 ms
52,224 KB
testcase_10 AC 37 ms
52,096 KB
testcase_11 AC 37 ms
51,968 KB
testcase_12 AC 38 ms
52,992 KB
testcase_13 AC 152 ms
153,680 KB
testcase_14 AC 74 ms
93,184 KB
testcase_15 AC 137 ms
135,668 KB
testcase_16 AC 148 ms
144,788 KB
testcase_17 AC 100 ms
102,400 KB
testcase_18 AC 70 ms
89,472 KB
testcase_19 AC 157 ms
153,900 KB
testcase_20 AC 55 ms
75,776 KB
testcase_21 AC 81 ms
101,888 KB
testcase_22 AC 103 ms
104,368 KB
testcase_23 AC 153 ms
154,172 KB
testcase_24 AC 151 ms
154,072 KB
testcase_25 AC 151 ms
153,900 KB
testcase_26 AC 154 ms
154,072 KB
testcase_27 AC 158 ms
154,116 KB
testcase_28 AC 36 ms
51,584 KB
testcase_29 AC 36 ms
51,952 KB
testcase_30 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

p = 998244353
N = int(input())
A = list(map(int,input().split()))
A.insert(0,0)
if N==1:
    ans = A[1]
else:
    a = 1
    i = 0
    while i<N-2:
        a = (a*2)%p
        i += 1
    b = 0
    for i in range(1,N+1):
        b = (b+(i+1)*A[i])%p
    ans = (a*b)%p
print(ans)
0