#P6031. CF1278F Cards 加强版
CF1278F Cards 加强版
Description
There are cards, and one of them is a joker. Shuffle these cards uniformly at random times. Let be the number of times the first card is the joker. Find the expected value of .
Take the answer modulo .
Input Format
One line with three positive integers .
Output Format
Output one integer in one line, which is the answer.
1234 2345 3456
398700213
998244352 1337 5000
326459680
233333333 114514 9982443
825888958
Hint
Constraints
For of the testdata, ;
For of the testdata, ;
For of the testdata, , .
Solution: iostream
Data: NaCly_Fish
Translated by ChatGPT 5
京公网安备 11011102002149号