Here's my code (a=pot at beginning b = bet, c = pot at the end)
Code: Select all
AC...
Moderator: Board moderators
Code: Select all
AC...
Now I got AC, but my assumptions contradicts the problem statements.david wrote:You are assuming that at at least one player must turn the roulette, but this isn't so. (Zero is a valid answer).
Also another assumption that I have to make is that P0<bet is valid. It is not clear from the problem statement whether this case is valid or not.In other case, the printed answer is one positive integer number telling the minimal number of players that could turn the roulette for the day corresponding to the annotations.
It should be "If P(t+1) < bet then the game ends...."If at some turn the pot was less than the bet, the game was ended for that day
Code: Select all
AC
Code: Select all
104 475 579
0 0 0
Code: Select all
1