Amr doesn't like Maths as he finds it really boring, so he usually sleeps in Maths lectures. But one day the teacher suspected that Amr is sleeping and asked him a question to make sure he wasn't.

First he gave Amr two positive integers n and k. Then he asked Amr, how many integer numbers x > 0 exist such that:

  * Decimal representation of x (without leading zeroes) consists of exactly n digits; 
  * There exists some integer y > 0 such that: 
    * <image>; 
    * decimal representation of y is a suffix of decimal representation of x. 



As the answer to this question may be pretty huge the teacher asked Amr to output only its remainder modulo a number m.

Can you help Amr escape this embarrassing situation?

Input

Input consists of three integers n, k, m (1 ≤ n ≤ 1000, 1 ≤ k ≤ 100, 1 ≤ m ≤ 109).

Output

Print the required number modulo m.

Examples

Input

1 2 1000


Output

4

Input

2 2 1000


Output

45

Input

5 3 1103


Output

590

Note

A suffix of a string S is a non-empty string that can be obtained by removing some number (possibly, zero) of first characters from S.
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ld = long double;
const ld eps = 1e-8;
template <class U, class V>
ostream& operator<<(ostream& out, const pair<U, V>& p) {
  return out << "(" << p.first << ", " << p.second << ")";
}
template <size_t i, class T>
ostream& print_tuple_utils(ostream& out, const T& tup) {
  if constexpr (i == tuple_size<T>::value)
    return out << ")";
  else
    return print_tuple_utils<i + 1, T>(out << (i ? ", " : "(") << get<i>(tup),
                                       tup);
}
template <class... U>
ostream& operator<<(ostream& out, const tuple<U...>& tup) {
  return print_tuple_utils<0, tuple<U...>>(out, tup);
}
template <class Con, class = decltype(begin(declval<Con>()))>
typename enable_if<!is_same<Con, string>::value, ostream&>::type operator<<(
    ostream& out, const Con& container) {
  out << "{";
  for (auto it = container.begin(); it != container.end(); ++it)
    out << (it == container.begin() ? "" : ", ") << *it;
  return out << "}";
}
const int maxn = 1030;
const int maxk = 111;
int n, k, m;
int add(int u, int v) {
  u += v;
  if (u >= m) u -= m;
  return u;
}
int mul(int u, int v) { return (int)(1ll * u * v % m); }
int addu(int& u, int v) { return u = add(u, v); }
int cnt[maxk], p10_k[maxn], p10_m[maxn];
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> n >> k >> m;
  p10_k[0] = p10_m[0] = 1;
  for (int i = 0; i++ < n + 10;) {
    p10_k[i] = p10_k[i - 1] * 10 % k;
    p10_m[i] = mul(p10_m[i - 1], 10);
  }
  for (int i = 0; i++ < 9;) addu(cnt[i % k], 1);
  int ans = 0;
  for (int suff_length = 1; suff_length < n; ++suff_length) {
    addu(ans, mul(cnt[0], mul(9, p10_m[n - suff_length - 1])));
    if (0)
      cerr << "["
              "suff_length"
              " = "
           << (suff_length) << "] "
           << "["
              "ans"
              " = "
           << (ans) << "] " << endl;
    int new_cnt[maxk];
    memset(new_cnt, 0, sizeof(new_cnt));
    for (int cur_mod = 0; cur_mod++ < k - 1;) {
      for (int dig = -1; ++dig < 10;) {
        int new_mod = (cur_mod + dig * p10_k[suff_length]) % k;
        addu(new_cnt[new_mod], cnt[cur_mod]);
      }
    }
    for (int dig = 0; dig++ < 9;) {
      int new_mod = p10_k[suff_length] * dig % k;
      addu(new_cnt[new_mod], 1);
    }
    memcpy(cnt, new_cnt, sizeof(cnt));
    if (0)
      cerr << "["
              "vector<int>(cnt, cnt + 10)"
              " = "
           << (vector<int>(cnt, cnt + 10)) << "] " << endl;
  }
  addu(ans, cnt[0]);
  cout << ans;
  return 0;
}
