Input
- The first line will be S, a number storing the total sum got when the player is planted. A "B" letter, meaning a Blackjack, will appear instead of a number when total sum is 21 with two cards.
- Second line is C a number that represents the value of a croupier’s initial card.
- The next ten lines will be Dn, that is the number of cards of each type (Ace, two, three, ...., nine, ten plus figures) that remain in the deck. Notice that more than one deck can be used in the game.
Output
The output will be three lines. The first line will contain the probability that the player has to win, the second the probability he has to tie, and the third the probability he’s got of losing. All probabilities must be expressed with one decimal, truncating the remaining decimal places (do not round).
Restrictions to be considered
3 < S < 22
0 < C < 11
0 <= Dn <= 128
Input
17 10 0 0 0 0 1 0 1 0 2 0
Output
25.0 25.0 50.0
Input
13 2 24 24 24 24 24 24 24 24 24 128
Output
39.9 0.0 60.0