結果
| 問題 | No.1510 Simple Integral |
| コンテスト | |
| ユーザー |
kozy
|
| 提出日時 | 2021-05-14 22:25:15 |
| 言語 | Python3 (3.14.2 + numpy 2.4.0 + scipy 1.16.3) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 291 bytes |
| 記録 | |
| コンパイル時間 | 665 ms |
| コンパイル使用メモリ | 12,544 KB |
| 実行使用メモリ | 11,008 KB |
| 最終ジャッジ日時 | 2024-10-02 02:02:18 |
| 合計ジャッジ時間 | 2,900 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 WA * 1 |
| other | AC * 2 WA * 10 RE * 31 |
ソースコード
N=int(input())
mod=998244353
A=list(map(int,input().split()))
ans=1
for i in range(N):
this=1
for j in range(N):
if i!=j:
this*=(A[i]**2-A[j]**2)
else:
this*=A[i]
this%=mod
ans+=pow(this,-1,mod)
ans%=mod
if i%2==0:
print((ans-1)%mod)
else:
print(-ans%mod)
kozy