题目描述
For positive integers $x$ and $y$, define $f(x, y)$ as follows:
- Interpret the decimal representations of $x$ and $y$ as strings and concatenate them in this order to obtain a string $z$. The value of $f(x, y)$ is the value of $z$ when interpreted as a decimal integer.
For example, $f(3, 14) = 314$ and $f(100, 1) = 1001$.
You are given a sequence of positive integers $A = (A_1, \ldots, A_N)$ of length $N$. Find the value of the following expression modulo $998244353$:
$\displaystyle \sum_{i=1}^{N-1}\sum_{j=i+1}^N f(A_i,A_j)$.
- $2 \leq N \leq 2 \times 10^5$
- $1 \leq A_i \leq 10^9$
- All input values are integers.