| 시간 제한 | 메모리 제한 | 제출 | 정답 | 맞힌 사람 | 정답 비율 |
|---|---|---|---|---|---|
| 1 초 | 2048 MB | 26 | 19 | 17 | 73.913% |
You are given three integers $p,ドル $k,ドル $t,ドル where $p$ is a prime number.
The set $S$ is defined as follows: $S = \{x \mid x \in N, \ 1 \leq x \leq p - 1, \ x \neq k \}$.
Find the sum of the products of all $t$-element subsets of $S,ドル modulo $p$.
The first line contains three integers $p,ドル $k,ドル $t$ ($p$ is a prime number; 1ドル \leq k \leq p-1$; 1ドル \leq t \leq p-2$; $p \leq 10^9$).
Print the sum of the products of all $t$-element subsets of $S,ドル modulo $p$.
7 5 3
1
11 6 7
3