結果

問題 No.1336 Union on Blackboard
ユーザー 👑 SPD_9X2SPD_9X2
提出日時 2021-01-15 21:47:30
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 83 ms / 2,000 ms
コード長 276 bytes
コンパイル時間 1,382 ms
コンパイル使用メモリ 86,836 KB
実行使用メモリ 76,540 KB
最終ジャッジ日時 2023-08-17 16:42:19
合計ジャッジ時間 4,342 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 76 ms
71,228 KB
testcase_01 AC 82 ms
76,480 KB
testcase_02 AC 79 ms
76,136 KB
testcase_03 AC 81 ms
76,208 KB
testcase_04 AC 80 ms
76,252 KB
testcase_05 AC 79 ms
76,208 KB
testcase_06 AC 80 ms
76,328 KB
testcase_07 AC 83 ms
76,496 KB
testcase_08 AC 81 ms
76,472 KB
testcase_09 AC 81 ms
76,496 KB
testcase_10 AC 80 ms
76,260 KB
testcase_11 AC 80 ms
76,472 KB
testcase_12 AC 80 ms
76,476 KB
testcase_13 AC 81 ms
76,528 KB
testcase_14 AC 80 ms
76,332 KB
testcase_15 AC 81 ms
76,472 KB
testcase_16 AC 81 ms
76,320 KB
testcase_17 AC 81 ms
76,476 KB
testcase_18 AC 79 ms
76,308 KB
testcase_19 AC 83 ms
76,324 KB
testcase_20 AC 80 ms
76,228 KB
testcase_21 AC 79 ms
76,444 KB
testcase_22 AC 81 ms
76,232 KB
testcase_23 AC 82 ms
76,136 KB
testcase_24 AC 83 ms
76,476 KB
testcase_25 AC 81 ms
76,468 KB
testcase_26 AC 81 ms
76,540 KB
testcase_27 AC 81 ms
76,256 KB
testcase_28 AC 82 ms
76,476 KB
testcase_29 AC 82 ms
76,480 KB
testcase_30 AC 73 ms
71,068 KB
testcase_31 AC 74 ms
71,056 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
from sys import stdin

mod = 10**9+7
TT = int(stdin.readline())

for loop in range(TT):

    N = int(stdin.readline())
    A = list(map(int,stdin.readline().split()))

    now = 0
    for i in A:
        now = now + i + now * i
        now %= mod

    print (now)
0