#arc172b. B - AtCoder Language

B - AtCoder Language

问题陈述

ATCoder语言具有 LL 个不同的字符。

有多少个由ATCoder语言中的字符组成的 NN 字符串 ss 满足以下条件?求以 998244353998244353 为模的计数。

  • 字符串 ss 的所有 KK 字符子序列都不同。

更确切地说,有 NCK_N\mathrm{C}_K 种方法可以获得 KK 个字符的字符串,方法是从字符串 ss 中提取 KK 个字符并将它们连接起来而不进行更改所有这些方法都必须生成不同的字符串。什么是 NCK_N\mathrm{C}_KNCK_N\mathrm{C}_K 是指从 NN 项中选择 KK 的方式的总数。

更准确地说, NCK_N\mathrm{C}_KN!N! 除以 K!×(NK)!K! \times (N-K)! 的值。

以上为机器翻译结果,仅供参考。

Problem Statement

The AtCoder language has LL different characters. How many NN-character strings ss consisting of characters in the AtCoder language satisfy the following condition? Find the count modulo 998244353998244353.

  • All KK-character subsequences of the string ss are different. More precisely, there are NCK_N\mathrm{C}_K ways to obtain a KK-character string by extracting KK characters from the string ss and concatenating them without changing the order, and all of these ways must generate different strings.

What is NCK_N\mathrm{C}_K?NCK_N\mathrm{C}_K refers to the total number of ways to choose KK from NN items. More precisely, NCK_N\mathrm{C}_K is the value of N!N! divided by K!×(NK)!K! \times (N-K)!.

Constraints

  • 1K<N5000001 \leq K \lt N \leq 500000
  • 1L1091 \leq L \leq 10^9
  • All input values are integers.

Input

The input is given from Standard Input in the following format:

NN KK LL

Output

Print the count modulo 998244353998244353.

Sample Input 1

4 3 2

Sample Output 1

2

If a and b represent the first and second characters in the language, the condition is satisfied by two strings: abab and baba.

Sample Input 2

100 80 26

Sample Output 2

496798269

Approximately 108610^{86} strings satisfy the condition, but here we print the count modulo 998244353998244353, which is 496798269496798269.

Sample Input 3

100 1 26

Sample Output 3

0

Sample Input 4

500000 172172 503746693

Sample Output 4

869120

What is NCK_N\mathrm{C}_K?NCK_N\mathrm{C}_K refers to the total number of ways to choose KK from NN items. More precisely, NCK_N\mathrm{C}_K is the value of N!N! divided by K!×(NK)!K! \times (N-K)!.