#include <bits/stdc++.h>
using namespace std;
void file(string s) {
  freopen((s + ".in").c_str(), "r", stdin);
  freopen((s + ".out").c_str(), "w", stdout);
}
template <typename Tp>
void read(Tp &x) {
  int fh = 1;
  char c = getchar();
  x = 0;
  while (c > '9' || c < '0') {
    if (c == '-') {
      fh = -1;
    }
    c = getchar();
  }
  while (c >= '0' && c <= '9') {
    x = (x << 1) + (x << 3) + (c & 15);
    c = getchar();
  }
  x *= fh;
}
template <typename Tp>
void read_(Tp &x, int Mod) {
  int fh = 1;
  char c = getchar();
  x = 0;
  while (c > '9' || c < '0') {
    if (c == '-') {
      fh = -1;
    }
    c = getchar();
  }
  while (c >= '0' && c <= '9') {
    x = (x * 10ll + c - '0') % Mod;
    c = getchar();
  }
  x *= fh;
}
int ksm(int b, int p, int Mod = 998244353) {
  int ret = 1;
  while (p) {
    if (p & 1) ret = 1ll * ret * b % Mod;
    b = 1ll * b * b % Mod;
    p >>= 1;
  }
  return ret;
}
namespace Poly {
const int Gmod = 3;
int tr[1000005], Wn[1000005];
int LG[1000005], inv[1000005];
int mxN;
void prep(int nmax) {
  for (mxN = 1; mxN < nmax; mxN <<= 1)
    ;
  LG[0] = -1;
  for (int i = 2; i <= mxN; ++i) LG[i] = LG[i >> 1] + 1;
  inv[1] = 1;
  for (int i = 2; i <= mxN; ++i)
    inv[i] = 1ll * (998244353 - 998244353 / i) * inv[998244353 % i] % 998244353;
  for (int i = 1; i < mxN; ++i)
    tr[i] = ((tr[i >> 1] >> 1) | ((i & 1) ? (mxN >> 1) : 0));
  for (int len = 1; len < mxN; len <<= 1) {
    Wn[len] = 1;
    int wn = ksm(Gmod, (998244353 - 1) / (len << 1));
    for (int j = 1; j < len; ++j)
      Wn[len + j] = 1ll * Wn[len + j - 1] * wn % 998244353;
  }
}
unsigned long long tf[1000005];
void ntt(vector<int> &f, int N) {
  int tn = LG[mxN / N];
  for (int i = 0; i < N; ++i) tf[tr[i] >> tn] = f[i];
  for (int len = 1; len < N; len <<= 1) {
    for (int i = 0; i < N; i += (len << 1)) {
      for (int j = 0; j < len; ++j) {
        unsigned x = tf[i + j + len] * Wn[len + j] % 998244353;
        tf[i + j + len] = (tf[i + j] + 998244353 - x);
        tf[i + j] = (tf[i + j] + x);
      }
    }
  }
  for (int i = 0; i < N; ++i) f[i] = tf[i] % 998244353;
}
void dnt(vector<int> &f, int N) {
  reverse(f.begin() + 1, f.end());
  ntt(f, N);
  int invN = inv[N];
  for (int i = 0; i < N; ++i) f[i] = 1ll * f[i] * invN % 998244353;
}
vector<int> fix(vector<int> a, int n) {
  a.resize(n);
  return a;
}
int calcfx(vector<int> a, int x) {
  int ret = 0, nn = a.size();
  for (int i = 0, t = 1; i < nn; ++i, t = 1ll * t * x % 998244353) {
    ret = ret + 1ll * a[i] * t % 998244353;
    if (ret >= 998244353) ret -= 998244353;
  }
  return ret;
}
vector<int> operator+(vector<int> a, vector<int> b) {
  int nn = max(a.size(), b.size());
  a.resize(nn);
  for (int i = 0; i < nn; ++i) {
    a[i] = a[i] + b[i];
    if (a[i] >= 998244353) a[i] -= 998244353;
  }
  return a;
}
vector<int> operator-(vector<int> a, vector<int> b) {
  int nn = max(a.size(), b.size());
  a.resize(nn);
  for (int i = 0; i < nn; ++i) {
    a[i] = a[i] - b[i];
    if (a[i] < 0) a[i] += 998244353;
  }
  return a;
}
vector<int> operator*(vector<int> a, int x) {
  int nn = a.size();
  for (int i = 0; i < nn; ++i) a[i] = 1ll * a[i] * x % 998244353;
  return a;
}
vector<int> operator*(vector<int> a, vector<int> b) {
  if (a.empty() || b.empty()) return vector<int>();
  int nn = a.size() + b.size() - 1, N = (1 << (LG[nn - 1] + 1));
  a.resize(N), b.resize(N);
  ntt(a, N);
  ntt(b, N);
  for (int i = 0; i < N; ++i) a[i] = 1ll * a[i] * b[i] % 998244353;
  dnt(a, N);
  return fix(a, nn);
}
}  // namespace Poly
using namespace Poly;
int frac[20000005], frinv[20000005];
void prepr(int N) {
  frac[0] = 1;
  for (int i = 1; i <= N; ++i) frac[i] = 1ll * frac[i - 1] * i % 998244353;
  frinv[N] = ksm(frac[N], 998244353 - 2);
  for (int i = N; i; --i) frinv[i - 1] = 1ll * frinv[i] * i % 998244353;
}
int Binom(int x, int y) {
  if (x < y || y < 0) return 0;
  return 1ll * frac[x] * frinv[y] % 998244353 * frinv[x - y] % 998244353;
}
namespace Striling {
vector<int> f1, f2, S2;
void get_S2(int N) {
  f1.resize(N + 1);
  f2.resize(N + 1);
  for (int i = 0; i <= N; ++i) {
    f1[i] = 1ll * ksm(i, N) * frinv[i] % 998244353;
    f2[i] = frinv[i];
    if (i & 1) f2[i] = 998244353 - f2[i];
  }
  S2 = f1 * f2;
}
}  // namespace Striling
int n, m, k;
int St2[1000005];
signed main() {
  read(n);
  read(m);
  read(k);
  prepr(k);
  prep((k + 1) << 1);
  Striling::get_S2(k);
  for (int i = 0; i <= k; ++i) St2[i] = Striling::S2[i];
  int ans = 0;
  int t1 = 1;
  for (int i = 0; i <= k; ++i) {
    ans = (ans + 1ll * St2[i] * t1 % 998244353 * ksm(ksm(m, i), 998244353 - 2) %
                     998244353) %
          998244353;
    t1 = 1ll * t1 * (n - i) % 998244353;
  }
  printf("%d\n", ans);
  return 0;
}

### Prompt

Please create a solution in cpp to the following problem:

Consider the following experiment. You have a deck of m cards, and exactly one card is a joker. n times, you do the following: shuffle the deck, take the top card of the deck, look at it and return it into the deck.

Let x be the number of times you have taken the joker out of the deck during this experiment. Assuming that every time you shuffle the deck, all m! possible permutations of cards are equiprobable, what is the expected value of x^k? Print the answer modulo 998244353.

Input

The only line contains three integers n, m and k (1 ≤ n, m < 998244353, 1 ≤ k ≤ 5000).

Output

Print one integer — the expected value of x^k, taken modulo 998244353 (the answer can always be represented as an irreducible fraction a/b, where b mod 998244353 ≠ 0; you have to print a ⋅ b^{-1} mod 998244353).

Examples

Input


1 1 1


Output


1


Input


1 1 5000


Output


1


Input


2 2 2


Output


499122178


Input


998244352 1337 5000


Output


326459680

### Response

```cpp
#include <bits/stdc++.h>
using namespace std;
void file(string s) {
  freopen((s + ".in").c_str(), "r", stdin);
  freopen((s + ".out").c_str(), "w", stdout);
}
template <typename Tp>
void read(Tp &x) {
  int fh = 1;
  char c = getchar();
  x = 0;
  while (c > '9' || c < '0') {
    if (c == '-') {
      fh = -1;
    }
    c = getchar();
  }
  while (c >= '0' && c <= '9') {
    x = (x << 1) + (x << 3) + (c & 15);
    c = getchar();
  }
  x *= fh;
}
template <typename Tp>
void read_(Tp &x, int Mod) {
  int fh = 1;
  char c = getchar();
  x = 0;
  while (c > '9' || c < '0') {
    if (c == '-') {
      fh = -1;
    }
    c = getchar();
  }
  while (c >= '0' && c <= '9') {
    x = (x * 10ll + c - '0') % Mod;
    c = getchar();
  }
  x *= fh;
}
int ksm(int b, int p, int Mod = 998244353) {
  int ret = 1;
  while (p) {
    if (p & 1) ret = 1ll * ret * b % Mod;
    b = 1ll * b * b % Mod;
    p >>= 1;
  }
  return ret;
}
namespace Poly {
const int Gmod = 3;
int tr[1000005], Wn[1000005];
int LG[1000005], inv[1000005];
int mxN;
void prep(int nmax) {
  for (mxN = 1; mxN < nmax; mxN <<= 1)
    ;
  LG[0] = -1;
  for (int i = 2; i <= mxN; ++i) LG[i] = LG[i >> 1] + 1;
  inv[1] = 1;
  for (int i = 2; i <= mxN; ++i)
    inv[i] = 1ll * (998244353 - 998244353 / i) * inv[998244353 % i] % 998244353;
  for (int i = 1; i < mxN; ++i)
    tr[i] = ((tr[i >> 1] >> 1) | ((i & 1) ? (mxN >> 1) : 0));
  for (int len = 1; len < mxN; len <<= 1) {
    Wn[len] = 1;
    int wn = ksm(Gmod, (998244353 - 1) / (len << 1));
    for (int j = 1; j < len; ++j)
      Wn[len + j] = 1ll * Wn[len + j - 1] * wn % 998244353;
  }
}
unsigned long long tf[1000005];
void ntt(vector<int> &f, int N) {
  int tn = LG[mxN / N];
  for (int i = 0; i < N; ++i) tf[tr[i] >> tn] = f[i];
  for (int len = 1; len < N; len <<= 1) {
    for (int i = 0; i < N; i += (len << 1)) {
      for (int j = 0; j < len; ++j) {
        unsigned x = tf[i + j + len] * Wn[len + j] % 998244353;
        tf[i + j + len] = (tf[i + j] + 998244353 - x);
        tf[i + j] = (tf[i + j] + x);
      }
    }
  }
  for (int i = 0; i < N; ++i) f[i] = tf[i] % 998244353;
}
void dnt(vector<int> &f, int N) {
  reverse(f.begin() + 1, f.end());
  ntt(f, N);
  int invN = inv[N];
  for (int i = 0; i < N; ++i) f[i] = 1ll * f[i] * invN % 998244353;
}
vector<int> fix(vector<int> a, int n) {
  a.resize(n);
  return a;
}
int calcfx(vector<int> a, int x) {
  int ret = 0, nn = a.size();
  for (int i = 0, t = 1; i < nn; ++i, t = 1ll * t * x % 998244353) {
    ret = ret + 1ll * a[i] * t % 998244353;
    if (ret >= 998244353) ret -= 998244353;
  }
  return ret;
}
vector<int> operator+(vector<int> a, vector<int> b) {
  int nn = max(a.size(), b.size());
  a.resize(nn);
  for (int i = 0; i < nn; ++i) {
    a[i] = a[i] + b[i];
    if (a[i] >= 998244353) a[i] -= 998244353;
  }
  return a;
}
vector<int> operator-(vector<int> a, vector<int> b) {
  int nn = max(a.size(), b.size());
  a.resize(nn);
  for (int i = 0; i < nn; ++i) {
    a[i] = a[i] - b[i];
    if (a[i] < 0) a[i] += 998244353;
  }
  return a;
}
vector<int> operator*(vector<int> a, int x) {
  int nn = a.size();
  for (int i = 0; i < nn; ++i) a[i] = 1ll * a[i] * x % 998244353;
  return a;
}
vector<int> operator*(vector<int> a, vector<int> b) {
  if (a.empty() || b.empty()) return vector<int>();
  int nn = a.size() + b.size() - 1, N = (1 << (LG[nn - 1] + 1));
  a.resize(N), b.resize(N);
  ntt(a, N);
  ntt(b, N);
  for (int i = 0; i < N; ++i) a[i] = 1ll * a[i] * b[i] % 998244353;
  dnt(a, N);
  return fix(a, nn);
}
}  // namespace Poly
using namespace Poly;
int frac[20000005], frinv[20000005];
void prepr(int N) {
  frac[0] = 1;
  for (int i = 1; i <= N; ++i) frac[i] = 1ll * frac[i - 1] * i % 998244353;
  frinv[N] = ksm(frac[N], 998244353 - 2);
  for (int i = N; i; --i) frinv[i - 1] = 1ll * frinv[i] * i % 998244353;
}
int Binom(int x, int y) {
  if (x < y || y < 0) return 0;
  return 1ll * frac[x] * frinv[y] % 998244353 * frinv[x - y] % 998244353;
}
namespace Striling {
vector<int> f1, f2, S2;
void get_S2(int N) {
  f1.resize(N + 1);
  f2.resize(N + 1);
  for (int i = 0; i <= N; ++i) {
    f1[i] = 1ll * ksm(i, N) * frinv[i] % 998244353;
    f2[i] = frinv[i];
    if (i & 1) f2[i] = 998244353 - f2[i];
  }
  S2 = f1 * f2;
}
}  // namespace Striling
int n, m, k;
int St2[1000005];
signed main() {
  read(n);
  read(m);
  read(k);
  prepr(k);
  prep((k + 1) << 1);
  Striling::get_S2(k);
  for (int i = 0; i <= k; ++i) St2[i] = Striling::S2[i];
  int ans = 0;
  int t1 = 1;
  for (int i = 0; i <= k; ++i) {
    ans = (ans + 1ll * St2[i] * t1 % 998244353 * ksm(ksm(m, i), 998244353 - 2) %
                     998244353) %
          998244353;
    t1 = 1ll * t1 * (n - i) % 998244353;
  }
  printf("%d\n", ans);
  return 0;
}

```