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 JAVA):

Solution:
import java.util.*;
import java.io.*;
import java.math.BigInteger;
import java.text.*;

public class F1278 {

	static long[][] comb; // may need BigInteger, if the numbers are large, use a treemap

	static long modInverse(long a, long mod) {
		return BigInteger.valueOf(a).modInverse(BigInteger.valueOf(mod)).longValue();
	}

	static long modPow(long a, long e, long mod) // O(log e)
	{
		a %= mod;
		long res = 1;
		while (e > 0) {
			if ((e & 1) == 1)
				res = (res * a) % mod;
			a = (a * a) % mod;
			e >>= 1;
		}
		return res;
	}

//	static long nCr1(int n, int k) {
//		if (n < k)
//			return 0;
//		if (k == 0 || k == n)
//			return 1;
//		if (comb[n][k] != -1)
//			return comb[n][k];
//		if (n - k < k)
//			return comb[n][k] = nCr1(n, n - k);
//		return comb[n][k] = ((nCr1(n - 1, k - 1) + nCr1(n - 1, k)) % mod);
//	}

	static long mod = 998244353;

//	static long sum(long n, long k, long m) {
//		long sum = 0;
//		for (int i = 0; i <= n; i++) {
//			long w = modPow(i, k, mod);
//			w *= nCr1((int) n, i) % mod;
//			w %= mod;
//			w *= modPow(m - 1,i, mod);
//			w %= mod;
//			sum += w;
//			sum %= mod;
//		}
//		System.out.println(sum);
//		sum *= modPow(modInverse(m, mod), n, mod);
//		sum %= mod;
//		return sum;
//	}

	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);
		PrintWriter pw = new PrintWriter(System.out);
		long n = sc.nextInt();
		long m = sc.nextInt();
		int k = sc.nextInt();
//		comb = new long[(int) n + 1][(int) n + 1];
//		for (long[] xx : comb)
//			Arrays.fill(xx, -1);
		long[] c = new long[k];
		long[] nP = new long[k + 1];
		nP[0] = 1;
		for (int i = 1; i <= k; i++) {
			nP[i] = ((n - i + 1) * nP[i - 1]) % mod;
		}
		c[0] = 1;
		for (int i = 0; i < k; i++) {
			long mult = 1;
			for (int j = i; j > 0; j--) {
				c[j] += (mult * c[j - 1]) % mod;
				c[j] %= mod;
				mult++;
			}
		}
		long ans = 0;
		for (int i = 0; i < k; i++) {
			long w = 1;
			w *= c[i] * nP[k - i];
			w %= mod;
			w *= modPow(m, n - (k - i), mod);
			w %= mod;
			ans += w;
			ans %= mod;
//			pw.println(ans);
		}
//		pw.println(ans);
		ans *= modPow(modInverse(m, mod), n, mod);
		ans %= mod;
//		pw.println(Arrays.toString(nP));
//		pw.println(Arrays.toString(c));
		pw.println(ans);
//		pw.println(sum(n, k, m));
		pw.close();
	}

	static class Scanner {
		StringTokenizer st;
		BufferedReader br;

		public Scanner(InputStream s) {
			br = new BufferedReader(new InputStreamReader(s));
		}

		public Scanner(FileReader r) {
			br = new BufferedReader(r);
		}

		public String next() throws IOException {
			while (st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine());
			return st.nextToken();
		}

		public int nextInt() throws IOException {
			return Integer.parseInt(next());
		}

		public long nextLong() throws IOException {
			return Long.parseLong(next());
		}

		public String nextLine() throws IOException {
			return br.readLine();
		}

		public double nextDouble() throws IOException {
			String x = next();
			StringBuilder sb = new StringBuilder("0");
			double res = 0, f = 1;
			boolean dec = false, neg = false;
			int start = 0;
			if (x.charAt(0) == '-') {
				neg = true;
				start++;
			}
			for (int i = start; i < x.length(); i++)
				if (x.charAt(i) == '.') {
					res = Long.parseLong(sb.toString());
					sb = new StringBuilder("0");
					dec = true;
				} else {
					sb.append(x.charAt(i));
					if (dec)
						f *= 10;
				}
			res += Long.parseLong(sb.toString()) / f;
			return res * (neg ? -1 : 1);
		}

		public boolean ready() throws IOException {
			return br.ready();
		}

	}
}