Your job is to simulate this game given a sequence of dice rolls.
Input will consist of multiple test cases. Each test case will consist of one line containing an integer n (indicating the number of players in the game) and a string (specifying the dice rolls). There will be at most 10 players in any game, and the string will consist only of the characters 'L', 'C', 'R' and '.'. In some test cases, there may be more dice rolls than are needed (i.e., some player wins the game before you use all the dice rolls). If there are not enough dice rolls left to complete a turn (for example, only two dice rolls are left for a player with 3 or more chips) then those dice rolls should be ignored. A value of n = 0 will indicate end of input.
For each test case, output the phrase "Game i:" on a single line (where i is the case number starting at 1) followed by a description of the state of the game. This desciption will consist of n+1 lines of the form
Player 1:c1 Player 2:c2 ... Player n:cn Center:ct
where c1, c2 ... cn are the number of chips each player has at the time the simulation ended (either because some player has won or there are no more remaining dice rolls) and ct is the number of chips in the center pile. In addition, if some player has won, you should append the string "(W)" after their chip count; otherwise you should append the string "(*)" after the chip count of the player who is the next to roll. The only blank on any line should come before the game number or the player number. Use a single blank line to separate test cases.
3 LR.CCR.L.RLLLCLR.LL..R...CLR. 5 RL....C.L 0
Game 1: Player 1:0 Player 2:0 Player 3:6(W) Center:3 Game 2: Player 1:1 Player 2:4 Player 3:1 Player 4:4(*) Player 5:4 Center:1
NOTE: problem C from 2008 East Central Regional Contest.