結果

問題 No.3362 積分!!!
コンテスト
ユーザー 👑 ArcAki
提出日時 2025-11-20 20:03:26
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 33 ms / 2,000 ms
コード長 270 bytes
コンパイル時間 222 ms
コンパイル使用メモリ 12,288 KB
実行使用メモリ 10,496 KB
最終ジャッジ日時 2025-11-20 20:03:28
合計ジャッジ時間 1,695 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 6
other AC * 14
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

def main():
    n, a, b = map(int, input().split())
    f = 1
    for i in range(n+1):
        f *= i+1
    ans = 0
    for i in range(n+1):
        k = int(input())
        ans += k*(b**(i+1)-a**(i+1))*f//(i+1)
    print(ans//f)


if __name__ == "__main__":
    main()
0