結果
| 問題 |
No.1886 Sum of Slide Max
|
| コンテスト | |
| ユーザー |
ytft
|
| 提出日時 | 2022-03-28 18:10:00 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 156 ms / 2,000 ms |
| コード長 | 335 bytes |
| コンパイル時間 | 188 ms |
| コンパイル使用メモリ | 82,176 KB |
| 実行使用メモリ | 77,824 KB |
| 最終ジャッジ日時 | 2024-11-07 09:36:07 |
| 合計ジャッジ時間 | 3,399 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 9 |
ソースコード
import sys,bisect input=lambda:sys.stdin.readline().rstrip() mod=998244353 N=int(input()) a=[i+2 for i in range(N)] for i in range(N): temp=a[i] p=mod-2 a[i]=1 while p: if p%2: a[i]=(a[i]*temp)%mod temp=(temp**2)%mod p//=2 cur=1 for i in range(1,N+2): cur=(cur*i)%mod for i in range(N): print((a[i]*cur*(i+1)*(N-i))%mod)
ytft