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.
import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.BufferedWriter;
import java.io.Writer;
import java.io.OutputStreamWriter;
import java.util.InputMismatchException;
import java.io.IOException;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author prakharjain
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        OutputWriter out = new OutputWriter(outputStream);
        _1073E solver = new _1073E();
        solver.solve(1, in, out);
        out.close();
    }

    static class _1073E {
        int mod = 998244353;
        long[] tenpow = new long[20];

        public void solve(int testNumber, InputReader in, OutputWriter out) {
            long l = in.nextLong();
            long r = in.nextLong();

            int k = in.nextInt();

            tenpow[0] = 1;

            for (int i = 1; i < 20; i++) {
                tenpow[i] = 10 * tenpow[i - 1];
                tenpow[i] %= mod;
            }

            long ans = cal(r, k);

            ans -= cal(l - 1, k);

            ans %= mod;

            if (ans < 0) {
                ans += mod;
            }

            out.println(ans);
        }

        long cal(long num, int k) {
            if (num == 0) {
                return 0;
            }

            long cnum = num;

            int size = 0;
            while (cnum > 0) {
                cnum /= 10;
                size++;
            }

            int bitmax = 1 << 10;

            long[][][] dp = new long[size][bitmax][2];
            long[][][] dp2 = new long[size][bitmax][2];

            cnum = num;

            long ans = 0;
            for (int j = 0; j < bitmax; j++) {

                int cn = (int) (cnum % 10);
                int cnt = 0;
                for (int l = 0; l < 10; l++) {
                    if (((1 << l) & j) != 0) {
                        cnt++;
                    }
                }

                dp[size - 1][j][0] = dp[size - 1][j][1] = -1;
                if (cnt > k) {
                    continue;
                }
                //0
                for (int l = 9; l >= 0; l--) {
                    if (l == 0 && j == 0) {
                        if (size - 1 != 0) {
                            ans += dp[size - 1][j][0];
                            ans %= mod;
                        }
                    }
                    if (((1 << l) & j) == 0) {
                        if (cnt < k) {
                            update(dp, size - 1, j, 0, l);
                            dp2[size - 1][j][0]++;
                        }
                    } else {
                        update(dp, size - 1, j, 0, l);
                        dp2[size - 1][j][0]++;
                    }
                }
                //1
                for (int l = cn; l >= 0; l--) {
                    if (l == 0 && j == 0) {
                        if (size - 1 == 0) {
                            ans += dp[size - 1][j][1];
                            ans %= mod;
                        }
                    }
                    if (((1 << l) & j) == 0) {
                        if (cnt < k) {
                            update(dp, size - 1, j, 1, l);
                            dp2[size - 1][j][1]++;
                        }
                    } else {
                        update(dp, size - 1, j, 1, l);
                        dp2[size - 1][j][1]++;
                    }
                }
            }

            cnum /= 10;

            for (int i = size - 2; i >= 0; i--) {
                int cn = (int) (cnum % 10);
                for (int j = 0; j < bitmax; j++) {

                    int cnt = 0;
                    for (int l = 0; l < 10; l++) {
                        if (((1 << l) & j) != 0) {
                            cnt++;
                        }
                    }

                    dp[i][j][0] = dp[i][j][1] = -1;
                    if (cnt > k) {
                        continue;
                    }

                    int power = size - 1 - i;
                    //0
                    for (int l = 9; l >= 0; l--) {
                        if (l == 0 && j == 0) {
                            if (i != 0) {
                                ans += dp[i][j][0];
                                ans %= mod;
                            }
                        }
                        if (((1 << l) & j) == 0) {
                            if (cnt < k && dp[i + 1][j | (1 << l)][0] != -1) {
                                update(dp, i, j, 0, dp2[i + 1][j | (1 << l)][0] * l * tenpow[power] + dp[i + 1][j | (1 << l)][0]);
                                dp2[i][j][0] += dp2[i + 1][j | (1 << l)][0];
                                dp2[i][j][0] %= mod;
                            }
                        } else {
                            if (dp[i + 1][j][0] != -1) {
                                update(dp, i, j, 0, dp2[i + 1][j][0] * l * tenpow[power] + dp[i + 1][j][0]);
                                dp2[i][j][0] += dp2[i + 1][j][0];
                                dp2[i][j][0] %= mod;
                            }
                        }
                    }
                    //1
                    if (((1 << cn) & j) == 0) {
                        if (cnt < k && dp[i + 1][j | (1 << cn)][1] != -1) {
                            update(dp, i, j, 1, cn * dp2[i + 1][j | (1 << cn)][1] * tenpow[power] + dp[i + 1][j | (1 << cn)][1]);
                            dp2[i][j][1] += dp2[i + 1][j | (1 << cn)][1];
                            dp2[i][j][1] %= mod;
                        }
                    } else {
                        if (dp[i + 1][j][1] != -1) {
                            update(dp, i, j, 1, cn * dp2[i + 1][j][1] * tenpow[power] + dp[i + 1][j][1]);
                            dp2[i][j][1] += dp2[i + 1][j][1];
                            dp2[i][j][1] %= mod;
                        }
                    }
                    for (int l = cn - 1; l >= 0; l--) {
                        if (l == 0 && j == 0) {
                            if (i == 0) {
                                ans += dp[i][j][1];
                                ans %= mod;
                            }
                        }
                        if (((1 << l) & j) == 0) {
                            if (cnt < k && dp[i + 1][j | (1 << l)][0] != -1) {
                                update(dp, i, j, 1, l * dp2[i + 1][j | (1 << l)][0] * tenpow[power] + dp[i + 1][j | (1 << l)][0]);
                                dp2[i][j][1] += dp2[i + 1][j | (1 << l)][0];
                                dp2[i][j][1] %= mod;
                            }
                        } else {
                            if (dp[i + 1][j][0] != -1) {
                                update(dp, i, j, 1, l * dp2[i + 1][j][0] * tenpow[power] + dp[i + 1][j][0]);
                                dp2[i][j][1] += dp2[i + 1][j][0];
                                dp2[i][j][1] %= mod;
                            }
                        }
                    }
                }

                cnum /= 10;
            }

//        for (int j = 0; j < bitmax; j++) {
//
//            int cnt = 0;
//            for (int l = 0; l < 10; l++) {
//                if (((1 << l) & j) != 0) {
//                    cnt++;
//                }
//            }
//
//            if (cnt > k) {
//                continue;
//            }
//
//            if (dp[0][j][1] != -1)
//                ans += dp[0][j][1];
//
//            ans %= mod;
//        }

            return ans;
        }

        void update(long[][][] dp, int i, int j, int k, long val) {

            val %= mod;

            if (dp[i][j][k] == -1) {
                dp[i][j][k] = 0;
            }

            dp[i][j][k] += val;
            dp[i][j][k] %= mod;
        }

    }

    static class OutputWriter {
        private final PrintWriter writer;

        public OutputWriter(OutputStream outputStream) {
            writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));
        }

        public OutputWriter(Writer writer) {
            this.writer = new PrintWriter(writer);
        }

        public void close() {
            writer.close();
        }

        public void println(long i) {
            writer.println(i);
        }

    }

    static class InputReader {
        private InputStream stream;
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;
        private InputReader.SpaceCharFilter filter;

        public InputReader(InputStream stream) {
            this.stream = stream;
        }

        public static boolean isWhitespace(int c) {
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

        public int read() {
            if (numChars == -1) {
                throw new InputMismatchException();
            }
            if (curChar >= numChars) {
                curChar = 0;
                try {
                    numChars = stream.read(buf);
                } catch (IOException e) {
                    throw new InputMismatchException();
                }
                if (numChars <= 0) {
                    return -1;
                }
            }
            return buf[curChar++];
        }

        public int nextInt() {
            int c = read();
            while (isSpaceChar(c)) {
                c = read();
            }
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            int res = 0;
            do {
                if (c < '0' || c > '9') {
                    throw new InputMismatchException();
                }
                res *= 10;
                res += c - '0';
                c = read();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public long nextLong() {
            int c = read();
            while (isSpaceChar(c)) {
                c = read();
            }
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            long res = 0;
            do {
                if (c < '0' || c > '9') {
                    throw new InputMismatchException();
                }
                res *= 10;
                res += c - '0';
                c = read();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public boolean isSpaceChar(int c) {
            if (filter != null) {
                return filter.isSpaceChar(c);
            }
            return isWhitespace(c);
        }

        public interface SpaceCharFilter {
            public boolean isSpaceChar(int ch);

        }

    }
}

