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

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const int MAXK = 1e7, Mod = 998244353;
int s[MAXK + 10], p[MAXK + 10], inv[MAXK + 10], idk[MAXK + 10];
int v[MAXK + 10], prime[MAXK + 10], tot = 0;
int fastpow(int x, int p) {
  long long ans = 1;
  while (p) {
    if (p & 1) ans = ans * x % Mod;
    x = 1ll * x * x % Mod;
    p >>= 1;
  }
  return ans;
}
void get_idk(int n, int k) {
  idk[1] = 1;
  for (register int i = 2; i <= n; ++i) {
    if (!v[i]) {
      idk[i] = fastpow(i, k);
      v[i] = i;
      prime[++tot] = i;
    }
    for (register int j = 1; prime[j] * i <= n && j <= tot; ++j) {
      if (v[i] < prime[j]) break;
      v[i * prime[j]] = prime[j];
      idk[i * prime[j]] = 1ll * idk[i] * idk[prime[j]] % Mod;
    }
  }
}
void work1(int n, int k) {
  long long c = 1;
  s[k] = 1;
  for (register int i = k - 1; i >= 0; --i) {
    long long P = (k - i) % 2 == 0 ? p[k - i] : Mod - p[k - i];
    c = c * inv[k - i] % Mod * (n - i - 1) % Mod;
    s[i] = 1ll * (Mod + 1 - p[1]) * s[i + 1] % Mod + c * P % Mod;
    s[i] %= Mod;
  }
}
void work2(int n) {
  s[n] = 1;
  for (register int i = n - 1; i >= 0; --i)
    s[i] = 1ll * (Mod + 1 - p[1]) * s[i + 1] % Mod;
}
signed main() {
  int n, m, k;
  scanf("%d%d%d", &n, &m, &k);
  p[0] = 1;
  p[1] = fastpow(m, Mod - 2);
  inv[1] = 1;
  for (register int i = 2; i <= k; ++i) {
    int r = Mod % i, q = Mod / i;
    inv[i] = 1ll * inv[r] * (Mod - q) % Mod;
  }
  for (register int i = 2; i <= k; ++i) p[i] = 1ll * p[i - 1] * p[1] % Mod;
  get_idk(k, k);
  if (n <= k)
    work2(n);
  else
    work1(n, k);
  long long ans = 0, c = 1;
  for (register int i = 1; i <= k; ++i) {
    c = c * (n - i + 1) % Mod * inv[i] % Mod;
    int tmp = 1ll * idk[i] * c % Mod * p[i] % Mod * s[i] % Mod;
    ans = (ans + tmp) % Mod;
  }
  printf("%lld\n", ans);
  return 0;
}