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 LN = 18, maxn = (1 << LN);
const long long mod = (long long)(998244353);
int fact[maxn], inv_fact[maxn], poww_r[maxn], poww_inv_r[maxn];
int mul(long long a, long long b) {
  long long ret = (a * b) % mod;
  return (int)(ret);
}
int add(int a, int b) {
  int ret = a + b;
  if (ret >= mod) {
    ret -= mod;
  }
  return ret;
}
int poww(int a, int b) {
  int x = 1, y = a;
  while (b > 0) {
    if (b % 2 == 1) {
      x = mul(x, y);
    }
    y = mul(y, y);
    b /= 2;
  }
  return x;
}
void build() {
  fact[0] = 1;
  for (int i = 1; i < maxn; i++) {
    fact[i] = mul(fact[i - 1], i);
  }
  inv_fact[maxn - 1] = poww(fact[maxn - 1], mod - 2);
  for (int i = maxn - 2; i >= 0; i--) {
    inv_fact[i] = mul(inv_fact[i + 1], i + 1);
  }
}
int C(int n, int r) {
  int num = fact[n], den = mul(inv_fact[r], inv_fact[n - r]);
  return mul(num, den);
}
vector<int> upper;
const int r = 3, inv_r = poww(r, mod - 2);
void pre() {
  int zz = poww(r, (mod - 1) >> LN), curr = 1;
  for (int i = 0; i < maxn; i++) {
    poww_r[i] = curr;
    curr = mul(curr, zz);
  }
  for (int i = 0; i < maxn; i++) {
    poww_inv_r[i] = (i == 0) ? 1 : poww_r[maxn - i];
  }
  fact[0] = 1;
  for (int i = 1; i < maxn; i++) {
    fact[i] = mul(fact[i - 1], i);
  }
  inv_fact[maxn - 1] = poww(fact[maxn - 1], mod - 2);
  for (int i = maxn - 2; i >= 0; i--) {
    inv_fact[i] = mul(inv_fact[i + 1], i + 1);
  }
}
void fft(vector<int> &a, bool invert) {
  int n = a.size();
  for (int i = 1, j = 0; i < n; i++) {
    int bit = n >> 1;
    for (; j >= bit; bit >>= 1) {
      j -= bit;
    }
    j += bit;
    if (i < j) {
      swap(a[i], a[j]);
    }
  }
  for (int len = 2; len <= n; len <<= 1) {
    int additive = maxn / len;
    for (int i = 0; i < n; i += len) {
      int now = 0;
      for (int j = 0; j < len / 2; j++) {
        int u = a[i + j],
            v = mul(a[i + j + len / 2], invert ? poww_inv_r[now] : poww_r[now]);
        a[i + j] = add(u, v);
        a[i + j + len / 2] = add(u, mod - v);
        now += additive;
      }
    }
  }
}
vector<int> mult(vector<int> &a, vector<int> &b) {
  int sz = 1;
  while (sz < max(a.size(), b.size())) {
    sz *= 2;
  }
  sz *= 2;
  vector<int> fa(sz), fb(sz);
  for (int i = 0; i < a.size(); i++) {
    fa[i] = a[i];
  }
  for (int i = 0; i < b.size(); i++) {
    fb[i] = b[i];
  }
  fft(fa, false);
  fft(fb, false);
  for (int i = 0; i < sz; i++) {
    fa[i] = mul(fa[i], fb[i]);
  }
  fft(fa, true);
  int inv_sz = poww(sz, mod - 2);
  for (int i = 0; i < sz; i++) {
    fa[i] = mul(fa[i], inv_sz);
  }
  while (fa.back() == 0) {
    fa.pop_back();
  }
  return fa;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  build();
  pre();
  int n, m, k;
  cin >> n >> m >> k;
  upper.resize(k + 1);
  upper[0] = 1;
  int last_used = n;
  for (int i = 1; i <= k; i++) {
    upper[i] = mul(upper[i - 1], last_used);
    last_used--;
  }
  vector<int> p1(k + 1), p2(k + 1);
  int curr = 1;
  for (int i = 0; i <= k; i++) {
    p1[i] = mul(poww(i, k), inv_fact[i]);
    p2[i] = mul(curr, inv_fact[i]);
    curr = mul(curr, mod - 1);
  }
  vector<int> res = mult(p1, p2);
  int ans = 0, inv = poww(m, mod - 2), curr_inv = inv;
  for (int i = 1; i <= min(n, k); i++) {
    int curr = mul(upper[i], curr_inv);
    curr = mul(curr, res[i]);
    ans = add(ans, curr);
    curr_inv = mul(curr_inv, inv);
  }
  cout << ans << endl;
  return 0;
}