We have an array $$$a$$$ of $$$n$$$ integers, and an initially empty sheet of paper.
We will do the following operations in-order $$$m$$$ times:
You are asked to calculate the probability that the integers written on the sheet are non-decreasing. Output the calculated value modulo $$$998244353$$$.
The first and only line contains two positive integers $$$n$$$ and $$$m$$$ $$${(1 \le n, \space m \le 10^6)}$$$ — the length of the array and the number of times we repeat the operations.
The following line contains $$$n$$$ integers $$$a_1, \space a_2, \space \dots, \space a_n$$$ $$$(1 \le a_i \le n)$$$ — the elements of the array $$$a$$$.
Output one integer, the probability that the integers written on the sheet are non-decreasing modulo $$$998244353$$$.
3 21 1 2
110916040
The possible final sequences on the paper are :
| Name |
|---|


