#include <bits/stdc++.h>
using namespace std;
int inline read() {
  int num = 0, neg = 1;
  char c = getchar();
  while (!isdigit(c)) {
    if (c == '-') neg = -1;
    c = getchar();
  }
  while (isdigit(c)) {
    num = (num << 3) + (num << 1) + c - '0';
    c = getchar();
  }
  return num * neg;
}
const int maxn = 8000010, mod = 998244353, G = 3, xsc = 1;
int invG, n, k, g[maxn], f[maxn], t[maxn], R[maxn], len, x;
void polyprint(int *f, int n) {
  for (int i = 0; i <= n; i++) printf("%d ", f[i]);
  cout << endl;
}
int ksm(int x, int y) {
  int ans = 1;
  while (y) {
    if (y & 1) ans = 1ll * ans * x % mod;
    x = 1ll * x * x % mod;
    y >>= 1;
  }
  return ans;
}
void NTT(int *A, int flag) {
  for (int i = 0; i < x; i++)
    if (i < R[i]) swap(A[i], A[R[i]]);
  for (int mid = 1; mid < x; mid <<= 1) {
    int g;
    if (flag)
      g = ksm(G, (mod - 1) / (mid << 1));
    else
      g = ksm(invG, (mod - 1) / (mid << 1));
    for (int j = 0; j < x; j += (mid << 1)) {
      int sum = 1;
      for (int k = 0; k < mid; k++) {
        int A1 = A[j + k], A2 = 1ll * sum * A[j + k + mid] % mod;
        A[j + k] = (A1 + A2) % mod;
        A[j + k + mid] = ((A1 - A2) % mod + mod) % mod;
        sum = 1ll * sum * g % mod;
      }
    }
  }
  if (!flag) {
    int X = ksm(x, mod - 2);
    for (int i = 0; i < x; i++) A[i] = 1ll * A[i] * X % mod;
  }
}
void polymul(int *a, int *b, int n, int m) {
  x = 1;
  len = 0;
  while (n + m >= x) x <<= 1, len++;
  for (int i = 0; i < x; i++) R[i] = (R[i >> 1] >> 1) | ((i & 1) << len - 1);
  NTT(a, 1);
  NTT(b, 1);
  for (int i = 0; i <= x; i++) a[i] = 1ll * a[i] * b[i] % mod;
  NTT(a, 0);
  NTT(b, 0);
}
void work(int r) {
  int mx = 10;
  while (r) {
    if (r & 1) {
      x = 1;
      len = 0;
      while (2 * mx >= x) x <<= 1, len++;
      for (int i = 0; i < x; i++)
        R[i] = (R[i >> 1] >> 1) | ((i & 1) << len - 1);
      NTT(f, 1);
      NTT(g, 1);
      for (int i = 0; i <= x; i++) f[i] = 1ll * f[i] * g[i] % mod;
      NTT(f, 0);
      NTT(g, 0);
    }
    x = 1;
    len = 0;
    while (2 * mx >= x) x <<= 1, len++;
    for (int i = 0; i < x; i++) R[i] = (R[i >> 1] >> 1) | ((i & 1) << len - 1);
    NTT(g, 1);
    for (int i = 0; i <= x; i++) g[i] = 1ll * g[i] * g[i] % mod;
    NTT(g, 0);
    r >>= 1;
    mx *= 2;
  }
  int ans = 0;
  for (int i = 0; i <= 9 * n / 2; i++)
    ans = (ans + 1ll * f[i] * f[i] % mod) % mod;
  cout << ans;
}
int main() {
  invG = ksm(G, mod - 2);
  n = read();
  k = read();
  f[0] = 1;
  for (int i = 1; i <= k; i++) {
    int x = read();
    g[x] = 1;
  }
  work(n / 2);
  return 0;
}

### Prompt

Construct a Cpp code solution to the problem outlined:

All bus tickets in Berland have their numbers. A number consists of n digits (n is even). Only k decimal digits d_1, d_2, ..., d_k can be used to form ticket numbers. If 0 is among these digits, then numbers may have leading zeroes. For example, if n = 4 and only digits 0 and 4 can be used, then 0000, 4004, 4440 are valid ticket numbers, and 0002, 00, 44443 are not.

A ticket is lucky if the sum of first n / 2 digits is equal to the sum of remaining n / 2 digits. 

Calculate the number of different lucky tickets in Berland. Since the answer may be big, print it modulo 998244353.

Input

The first line contains two integers n and k (2 ≤ n ≤ 2 ⋅ 10^5, 1 ≤ k ≤ 10) — the number of digits in each ticket number, and the number of different decimal digits that may be used. n is even.

The second line contains a sequence of pairwise distinct integers d_1, d_2, ..., d_k (0 ≤ d_i ≤ 9) — the digits that may be used in ticket numbers. The digits are given in arbitrary order.

Output

Print the number of lucky ticket numbers, taken modulo 998244353.

Examples

Input

4 2
1 8


Output

6


Input

20 1
6


Output

1


Input

10 5
6 1 4 0 3


Output

569725


Input

1000 7
5 4 0 1 8 3 2


Output

460571165

Note

In the first example there are 6 lucky ticket numbers: 1111, 1818, 1881, 8118, 8181 and 8888.

There is only one ticket number in the second example, it consists of 20 digits 6. This ticket number is lucky, so the answer is 1.

### Response

```cpp
#include <bits/stdc++.h>
using namespace std;
int inline read() {
  int num = 0, neg = 1;
  char c = getchar();
  while (!isdigit(c)) {
    if (c == '-') neg = -1;
    c = getchar();
  }
  while (isdigit(c)) {
    num = (num << 3) + (num << 1) + c - '0';
    c = getchar();
  }
  return num * neg;
}
const int maxn = 8000010, mod = 998244353, G = 3, xsc = 1;
int invG, n, k, g[maxn], f[maxn], t[maxn], R[maxn], len, x;
void polyprint(int *f, int n) {
  for (int i = 0; i <= n; i++) printf("%d ", f[i]);
  cout << endl;
}
int ksm(int x, int y) {
  int ans = 1;
  while (y) {
    if (y & 1) ans = 1ll * ans * x % mod;
    x = 1ll * x * x % mod;
    y >>= 1;
  }
  return ans;
}
void NTT(int *A, int flag) {
  for (int i = 0; i < x; i++)
    if (i < R[i]) swap(A[i], A[R[i]]);
  for (int mid = 1; mid < x; mid <<= 1) {
    int g;
    if (flag)
      g = ksm(G, (mod - 1) / (mid << 1));
    else
      g = ksm(invG, (mod - 1) / (mid << 1));
    for (int j = 0; j < x; j += (mid << 1)) {
      int sum = 1;
      for (int k = 0; k < mid; k++) {
        int A1 = A[j + k], A2 = 1ll * sum * A[j + k + mid] % mod;
        A[j + k] = (A1 + A2) % mod;
        A[j + k + mid] = ((A1 - A2) % mod + mod) % mod;
        sum = 1ll * sum * g % mod;
      }
    }
  }
  if (!flag) {
    int X = ksm(x, mod - 2);
    for (int i = 0; i < x; i++) A[i] = 1ll * A[i] * X % mod;
  }
}
void polymul(int *a, int *b, int n, int m) {
  x = 1;
  len = 0;
  while (n + m >= x) x <<= 1, len++;
  for (int i = 0; i < x; i++) R[i] = (R[i >> 1] >> 1) | ((i & 1) << len - 1);
  NTT(a, 1);
  NTT(b, 1);
  for (int i = 0; i <= x; i++) a[i] = 1ll * a[i] * b[i] % mod;
  NTT(a, 0);
  NTT(b, 0);
}
void work(int r) {
  int mx = 10;
  while (r) {
    if (r & 1) {
      x = 1;
      len = 0;
      while (2 * mx >= x) x <<= 1, len++;
      for (int i = 0; i < x; i++)
        R[i] = (R[i >> 1] >> 1) | ((i & 1) << len - 1);
      NTT(f, 1);
      NTT(g, 1);
      for (int i = 0; i <= x; i++) f[i] = 1ll * f[i] * g[i] % mod;
      NTT(f, 0);
      NTT(g, 0);
    }
    x = 1;
    len = 0;
    while (2 * mx >= x) x <<= 1, len++;
    for (int i = 0; i < x; i++) R[i] = (R[i >> 1] >> 1) | ((i & 1) << len - 1);
    NTT(g, 1);
    for (int i = 0; i <= x; i++) g[i] = 1ll * g[i] * g[i] % mod;
    NTT(g, 0);
    r >>= 1;
    mx *= 2;
  }
  int ans = 0;
  for (int i = 0; i <= 9 * n / 2; i++)
    ans = (ans + 1ll * f[i] * f[i] % mod) % mod;
  cout << ans;
}
int main() {
  invG = ksm(G, mod - 2);
  n = read();
  k = read();
  f[0] = 1;
  for (int i = 1; i <= k; i++) {
    int x = read();
    g[x] = 1;
  }
  work(n / 2);
  return 0;
}

```