题目描述
Problem Description
Given positive integers $ N $ and $ A $.
Let $ m $ be a positive integer. Sai has $ m $ special dice numbered from $ 1 $ to $ m $. Sai will roll each die $ A $ times. Each roll of die $ i $ ($1 \le i \le m$) has a probability of $\frac{1}{i^2}$ of landing on a "hit". These trials are all independent events.
What is the probability of getting exactly $ N $ hits in total? This value depends on $ m $, but we want to find the limit of this probability as $ m $ approaches infinity.
Let this limit be $ p $. It can be proven that there exist unique rational numbers $c_0, \ldots, c_{N-1}$ such that $p = \sum_{j=0}^{N-1} c_j \pi^j$ (where $\pi$ is the mathematical constant pi). Output these $c_0, \ldots, c_{N-1}$ modulo $ 998244353 $.
When outputting a rational number modulo $ 998244353 $, represent it as an irreducible fraction $\frac{x}{y}$. Output the integer $ z $ in the range $ 0 $ to $ 998244353 - 1 $ such that $ x - yz $ is divisible by $ 998244353 $. Due to the constraints of this problem, the value to be output is uniquely determined.
Input Format
The input is given from the standard input in the following format:
$ N $ $ A $
Output Format
Output $c_0, \ldots, c_{N-1}$ in this order, separated by spaces, modulo $ 998244353 $.
Sample Input and Output
Sample Input #1
1 1
Sample Output #1
499122177
Sample Input #2
2 1
Sample Output #2
623902721 0
Sample Input #3
3 1
Sample Output #3
686292993 0 353544875
Sample Input #4
3 2
Sample Output #4
623902721 0 0
Sample Input #5
10 5
Sample Output #5
748591874 0 809083222 0 440705764 0 0 0 0 0
Notes/Hints
Constraints
- $1 \le A \le N \le 250,000$.
Partial Points
- Correct answer for a dataset where $N \le 100$ and $ A = 1 $ will award $ 10 $ points.
- Correct answer for a dataset where $ A = 1 $ will award an additional $ 10 $ points.
- Correct answer for the dataset without additional constraints will award an additional $ 80 $ points.
Sample Explanation 1
$p = \frac{1}{2}$.
Sample Explanation 2
$p = \frac{3}{8}$.
Sample Explanation 3
$p = \frac{5}{16} - \frac{1}{48} \pi^2$.
Sample Explanation 4
$p = \frac{3}{8}$.
输入格式
见题面 Input 部分
输出格式
见题面 Output 部分