1 人解决,2 人已尝试。
1 份提交通过,共有 4 份提交。
9.8 EMB 奖励。
单点时限: 1.0 sec
内存限制: 256 MB
Young Alisa likes to play the piano using only one finger. Unfortunately, Alisa never learned to play the piano, so her playing is entirely random. More precisely, any time she chooses a tone to play, she does it independently of all previous tones, and chooses each of the
Her good friend Mirta wants to listen to a composition containing
The first line of input contains the positive integer
The second line of input contains the positive integer
The third line of input contains the array of
In test cases worth 64 points in total, it will hold
The
The test data will be such that the expected number of key presses will always be an integer.
3 3 1 2 3
3 9 27
2 2 1 1
2 6
2 2 1 2
2 4
1 人解决,2 人已尝试。
1 份提交通过,共有 4 份提交。
9.8 EMB 奖励。