#include <bits/stdc++.h>
using namespace std;
template <typename T>
void chkmax(T &x, T y) {
  x = x > y ? x : y;
}
template <typename T>
void chkmin(T &x, T y) {
  x = x > y ? y : x;
}
template <typename T>
void read(T &x) {
  x = 0;
  int f = 1;
  char c = getchar();
  while (!isdigit(c)) {
    if (c == '-') f = -1;
    c = getchar();
  }
  while (isdigit(c)) x = x * 10 + c - '0', c = getchar();
  x *= f;
}
pair<int, int> f[110][1 << 11][2][2];
int a[110], pw[110];
long long l, r, K;
pair<int, int> dp(int pos, int s, bool lim, bool l, int tot) {
  if (tot > K) return make_pair(0, 0);
  if (pos == -1) return make_pair(!l, 0);
  if (f[pos][s][lim][l].first != -1) return f[pos][s][lim][l];
  int x = (lim) ? a[pos] : 9, s1 = 0, s2 = 0;
  for (int i = 0; i <= x; i++)
    if (!l) {
      pair<int, int> t = dp(pos - 1, s | (1 << i), lim && i == a[pos], l,
                            tot + ((s & (1 << i)) == 0));
      int tx = t.first, ty = t.second;
      s1 = (s1 + tx) % 998244353,
      s2 = (s2 + 1ll * i * pw[pos] % 998244353 * tx % 998244353) % 998244353,
      s2 = (s2 + ty) % 998244353;
    } else if (i == 0) {
      pair<int, int> t = dp(pos - 1, s, lim && i == a[pos], true, tot);
      int tx = t.first, ty = t.second;
      s1 = (s1 + tx) % 998244353, s2 = (s2 + ty) % 998244353;
    } else {
      pair<int, int> t =
          dp(pos - 1, s | (1 << i), lim && i == a[pos], false, tot + 1);
      int tx = t.first, ty = t.second;
      s1 = (s1 + tx) % 998244353,
      s2 = (s2 + 1ll * i * pw[pos] % 998244353 * tx % 998244353) % 998244353,
      s2 = (s2 + ty) % 998244353;
    }
  if (!lim && !l) f[pos][s][lim][l] = make_pair(s1, s2);
  return make_pair(s1, s2);
}
int solve(long long n) {
  int len = -1;
  long long x = n;
  while (x) a[++len] = x % 10, x /= 10;
  memset(f, -1, sizeof(f));
  pair<int, int> tmp = dp(len, 0, 1, 1, 0);
  return tmp.second;
}
int main() {
  read(l), read(r), read(K);
  pw[0] = 1;
  for (int i = 1; i <= 20; i++) pw[i] = 10ll * pw[i - 1] % 998244353;
  cout << (solve(r) - solve(l - 1) + 998244353) % 998244353 << "\n";
  return 0;
}
