Problem Statement
There is a tree with $N \times M + 1$ vertices numbered $0, 1, \dots, N \times M$. The $i$-th edge $(1 \leq i \leq N \times M)$ connects vertices $i$ and $\max(i - N, 0)$.
Vertex $0$ is painted. The other vertices are unpainted.
Takahashi is at vertex $0$. As long as there exists an unpainted vertex, he performs the following operation:
- He chooses one of the vertices adjacent to his current vertex uniformly at random (all choices are independent) and moves to that vertex. Then, if the vertex he is on is unpainted, he paints it.
Find the expected number of times he performs the operation, modulo $998244353$.
What is the expected value modulo $998244353$? It can be proved that the sought expected value is always rational. Under the constraints of this problem, when that value is expressed as an irreducible fraction $\frac{P}{Q}$, it can also be proved that $Q \not\equiv 0 \pmod{998244353}$. Then, there uniquely exists an integer $R$ such that $R \times Q \equiv P \pmod{998244353}, 0 \leq R \lt 998244353$. Report this $R$.
Constraints
$1 \leq N \leq 2 \times 10^5$$1 \leq M \leq 2 \times 10^5$$N$and$M$are integers.
Input
The input is given from Standard Input in the following format:
N M
Output
Print the expected number of times he performs the operation, modulo $998244353$.
样例
2 2
20
123456 185185
69292914
题面与样例版权归 AtCoder 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。