You are given two integers l and r (l ≤ r). Your task is to calculate the sum of numbers from l to r (including l and r) such that each number contains at most k different digits, and print this sum modulo 998244353.

For example, if k = 1 then you have to calculate all numbers from l to r such that each number is formed using only one digit. For l = 10, r = 50 the answer is 11 + 22 + 33 + 44 = 110.

Input

The only line of the input contains three integers l, r and k (1 ≤ l ≤ r < 10^{18}, 1 ≤ k ≤ 10) — the borders of the segment and the maximum number of different digits.

Output

Print one integer — the sum of numbers from l to r such that each number contains at most k different digits, modulo 998244353.

Examples

Input

10 50 2


Output

1230


Input

1 2345 10


Output

2750685


Input

101 154 2


Output

2189

Note

For the first example the answer is just the sum of numbers from l to r which equals to (50 ⋅ 51)/(2) - (9 ⋅ 10)/(2) = 1230. This example also explained in the problem statement but for k = 1.

For the second example the answer is just the sum of numbers from l to r which equals to (2345 ⋅ 2346)/(2) = 2750685.

For the third example the answer is 101 + 110 + 111 + 112 + 113 + 114 + 115 + 116 + 117 + 118 + 119 + 121 + 122 + 131 + 133 + 141 + 144 + 151 = 2189.
#include <bits/stdc++.h>
using namespace std;
const long long int K = 998244353;
long long int f[1055][25][25], d[1055][25][25];
long long int vsf[1055][25][25], vsd[1055][25][25];
long long int sf[1055][25][25], sd[1055][25][25];
long long int vssf[1055][25][25], vssd[1055][25][25];
long long int mu[24];
long long int k, a[20];
long long int calc_f(long long int bit, long long int n, long long int st) {
  if (n == -1) {
    if (bit == 0 && st == 0) return 1;
    return 0;
  }
  if (__builtin_popcountll(bit) > k || (bit & (1 << st)) == 0) return 0;
  if (vsf[bit][n][st]) return f[bit][n][st];
  vsf[bit][n][st] = 1;
  long long int Res = 0;
  for (int i = 0; i <= 9; i++) {
    if ((bit & (1 << st)))
      Res =
          (Res + calc_f(bit, n - 1, i) + calc_f(bit - (1 << st), n - 1, i)) % K;
  }
  return f[bit][n][st] = Res;
}
long long int calc_sf(long long int bit, long long int n, long long int st) {
  if (n == -1) {
    return 0;
  }
  if (__builtin_popcountll(bit) > k || (bit & (1 << st)) == 0) return 0;
  if (vssf[bit][n][st]) return sf[bit][n][st];
  vssf[bit][n][st] = 1;
  long long int Res = 0;
  for (int i = 0; i <= 9; i++) {
    if ((bit & (1 << st))) {
      Res =
          (Res + calc_sf(bit, n - 1, i) + calc_sf(bit - (1 << st), n - 1, i)) %
          K;
    }
  }
  Res = (Res + st * mu[n] % K * calc_f(bit, n, st) % K) % K;
  return sf[bit][n][st] = Res;
}
long long int calc_d(long long int bit, long long int n, long long int st) {
  if (n == -1) {
    if (bit == 0 && st == 0) return 1;
    return 0;
  }
  if (__builtin_popcountll(bit) > k || st > a[n] || (bit & (1 << st)) == 0)
    return 0;
  if (vsd[bit][n][st]) return d[bit][n][st];
  vsd[bit][n][st] = 1;
  long long int Res = 0;
  if (st == a[n]) {
    Res = (calc_d(bit, n - 1, a[n - 1]) +
           calc_d(bit - (1 << st), n - 1, a[n - 1]));
    Res %= K;
    for (int i = 0; i <= a[n - 1] - 1; i++) {
      Res =
          (Res + calc_f(bit, n - 1, i) + calc_f(bit - (1 << st), n - 1, i)) % K;
    }
  } else if (st < a[n]) {
    Res = calc_f(bit, n, st);
  }
  return d[bit][n][st] = Res;
}
long long int calc_sd(long long int bit, long long int n, long long int st) {
  if (n == -1) {
    return 0;
  }
  if (__builtin_popcountll(bit) > k || st > a[n] || (bit & (1 << st)) == 0)
    return 0;
  if (vssd[bit][n][st]) return sd[bit][n][st];
  vssd[bit][n][st] = 1;
  long long int Res = 0;
  if (st == a[n]) {
    Res = (calc_sd(bit, n - 1, a[n - 1]) +
           calc_sd(bit - (1 << st), n - 1, a[n - 1]));
    Res %= K;
    for (int i = 0; i <= a[n - 1] - 1; i++) {
      Res =
          (Res + calc_sf(bit, n - 1, i) + calc_sf(bit - (1 << st), n - 1, i)) %
          K;
    }
    Res = (Res + st * mu[n] % K * calc_d(bit, n, st) % K) % K;
  } else if (st < a[n]) {
    Res = calc_sf(bit, n, st);
  }
  return sd[bit][n][st] = Res;
}
void pre(long long int r) {
  int C = -1;
  while (r) {
    a[++C] = r % 10;
    r /= 10;
  }
}
long long int calc(long long int r) {
  if (r == 0) return 0;
  int C = -1;
  for (int i = 0; i <= 1024; i++) {
    for (int j = 0; j <= 20; j++) {
      for (int k = 0; k <= 10; k++) {
        vssf[i][j][k] = vssd[i][j][k] = vsf[i][j][k] = vsd[i][j][k] = 0;
      }
    }
  }
  while (r) {
    a[++C] = r % 10;
    r /= 10;
  }
  long long int Res = 0;
  for (int i = 1; i <= 1023; i++) {
    if (__builtin_popcountll(i) <= k) {
      for (int j = 1; j <= 9; j++) {
        for (int z = 0; z <= C - 1; z++) {
          Res = (Res + calc_sf(i, z, j)) % K;
        }
        Res = (Res + calc_sd(i, C, j)) % K;
      }
    }
  }
  return Res;
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(NULL);
  mu[0] = 1;
  for (int i = 1; i <= 18; i++) mu[i] = mu[i - 1] * 10 % K;
  long long int l, r;
  cin >> l >> r >> k;
  long long int res = (calc(r) - calc(l - 1) + K) % K;
  cout << res << endl;
  return 0;
}
