結果

問題 No.1824 門\松\列
ユーザー irumo8202irumo8202
提出日時 2022-01-28 22:47:24
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 141 ms / 2,000 ms
コード長 225 bytes
コンパイル時間 614 ms
コンパイル使用メモリ 87,168 KB
実行使用メモリ 93,184 KB
最終ジャッジ日時 2023-08-28 21:19:27
合計ジャッジ時間 1,792 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 90 ms
91,072 KB
testcase_01 AC 88 ms
91,144 KB
testcase_02 AC 109 ms
92,236 KB
testcase_03 AC 141 ms
93,184 KB
testcase_04 AC 108 ms
92,248 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

T = int(input())

M = 10 ** 6
res = [0] * (M + 1)
acc = [0] * (M + 1)
for i in range(3, M + 1):
    res[i] += res[i - 1] + i - 2
    acc[i] += acc[i - 1] + res[i]

for _ in range(T):
    N = int(input())
    print(acc[N] * 4)
0