#include <bits/stdc++.h>
std::mt19937 rng(
    (int)std::chrono::steady_clock::now().time_since_epoch().count());
const int MOD = 998244353;
const int me = 20;
const int ms = 1 << me;
long long fexp(long long x, long long e, long long mod = MOD) {
  long long ans = 1;
  x %= mod;
  for (; e > 0; e /= 2) {
    if (e & 1) {
      ans = ans * x % mod;
    }
    x = x * x % mod;
  }
  return ans;
}
bool test(long long x, long long p) {
  long long m = p - 1;
  for (int i = 2; i * i <= m; ++i)
    if (m % i == 0) {
      if (fexp(x, i, p) == 1) return false;
      if (fexp(x, m / i, p) == 1) return false;
    }
  return true;
}
int search(int p) {
  for (int i = p - 1; i >= 2; --i)
    if (test(i, p)) return i;
  return -1;
}
const int gen = search(MOD);
int bits[ms], r[ms + 1];
void pre(int n) {
  int LOG = 0;
  while (1 << (LOG + 1) < n) {
    LOG++;
  }
  for (int i = 1; i < n; i++) {
    bits[i] = (bits[i >> 1] >> 1) | ((i & 1) << LOG);
  }
}
void pre(int n, int root, int mod) {
  pre(n);
  r[0] = 1;
  for (int i = 1; i <= n; i++) {
    r[i] = (long long)r[i - 1] * root % mod;
  }
}
std::vector<int> fft(std::vector<int> a, int mod, bool inv = false) {
  int root = gen;
  if (inv) {
    root = fexp(root, mod - 2, mod);
  }
  int n = a.size();
  root = fexp(root, (mod - 1) / n, mod);
  pre(n, root, mod);
  for (int i = 0; i < n; i++) {
    int to = bits[i];
    if (i < to) {
      std::swap(a[i], a[to]);
    }
  }
  for (int len = 1; len < n; len *= 2) {
    for (int i = 0; i < n; i += len * 2) {
      int cur_root = 0;
      int delta = n / (2 * len);
      for (int j = 0; j < len; j++) {
        int u = a[i + j], v = (long long)a[i + j + len] * r[cur_root] % mod;
        a[i + j] = (u + v >= mod ? u + v - mod : u + v);
        a[i + j + len] = (u + mod - v >= mod ? u + mod - v - mod : u + mod - v);
        cur_root += delta;
      }
    }
  }
  if (inv) {
    int rev = fexp(n, mod - 2, mod);
    for (int i = 0; i < n; i++) a[i] = (long long)a[i] * rev % mod;
  }
  return a;
}
int main() {
  std::ios_base::sync_with_stdio(false);
  std::cin.tie(NULL);
  std::vector<int> poly(ms, 0);
  int n, k;
  std::cin >> n >> k;
  while (k--) {
    int v;
    std::cin >> v;
    poly[v]++;
  }
  poly = fft(poly, MOD);
  for (int i = 0; i < ms; i++) {
    poly[i] = fexp(poly[i], n / 2, MOD);
  }
  poly = fft(poly, MOD, true);
  long long ans = 0;
  for (int i = 0; i < ms; i++) {
    ans = (ans + (long long)poly[i] * poly[i]) % MOD;
  }
  std::cout << ans << '\n';
}

### Prompt

Please provide a CPP coded solution to the problem described below:

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>
std::mt19937 rng(
    (int)std::chrono::steady_clock::now().time_since_epoch().count());
const int MOD = 998244353;
const int me = 20;
const int ms = 1 << me;
long long fexp(long long x, long long e, long long mod = MOD) {
  long long ans = 1;
  x %= mod;
  for (; e > 0; e /= 2) {
    if (e & 1) {
      ans = ans * x % mod;
    }
    x = x * x % mod;
  }
  return ans;
}
bool test(long long x, long long p) {
  long long m = p - 1;
  for (int i = 2; i * i <= m; ++i)
    if (m % i == 0) {
      if (fexp(x, i, p) == 1) return false;
      if (fexp(x, m / i, p) == 1) return false;
    }
  return true;
}
int search(int p) {
  for (int i = p - 1; i >= 2; --i)
    if (test(i, p)) return i;
  return -1;
}
const int gen = search(MOD);
int bits[ms], r[ms + 1];
void pre(int n) {
  int LOG = 0;
  while (1 << (LOG + 1) < n) {
    LOG++;
  }
  for (int i = 1; i < n; i++) {
    bits[i] = (bits[i >> 1] >> 1) | ((i & 1) << LOG);
  }
}
void pre(int n, int root, int mod) {
  pre(n);
  r[0] = 1;
  for (int i = 1; i <= n; i++) {
    r[i] = (long long)r[i - 1] * root % mod;
  }
}
std::vector<int> fft(std::vector<int> a, int mod, bool inv = false) {
  int root = gen;
  if (inv) {
    root = fexp(root, mod - 2, mod);
  }
  int n = a.size();
  root = fexp(root, (mod - 1) / n, mod);
  pre(n, root, mod);
  for (int i = 0; i < n; i++) {
    int to = bits[i];
    if (i < to) {
      std::swap(a[i], a[to]);
    }
  }
  for (int len = 1; len < n; len *= 2) {
    for (int i = 0; i < n; i += len * 2) {
      int cur_root = 0;
      int delta = n / (2 * len);
      for (int j = 0; j < len; j++) {
        int u = a[i + j], v = (long long)a[i + j + len] * r[cur_root] % mod;
        a[i + j] = (u + v >= mod ? u + v - mod : u + v);
        a[i + j + len] = (u + mod - v >= mod ? u + mod - v - mod : u + mod - v);
        cur_root += delta;
      }
    }
  }
  if (inv) {
    int rev = fexp(n, mod - 2, mod);
    for (int i = 0; i < n; i++) a[i] = (long long)a[i] * rev % mod;
  }
  return a;
}
int main() {
  std::ios_base::sync_with_stdio(false);
  std::cin.tie(NULL);
  std::vector<int> poly(ms, 0);
  int n, k;
  std::cin >> n >> k;
  while (k--) {
    int v;
    std::cin >> v;
    poly[v]++;
  }
  poly = fft(poly, MOD);
  for (int i = 0; i < ms; i++) {
    poly[i] = fexp(poly[i], n / 2, MOD);
  }
  poly = fft(poly, MOD, true);
  long long ans = 0;
  for (int i = 0; i < ms; i++) {
    ans = (ans + (long long)poly[i] * poly[i]) % MOD;
  }
  std::cout << ans << '\n';
}

```