# Simple game of dice - what is the optimal strategy?

The game is pretty simple, whoever reaches 50 first wins, but there are a few important details:

• 2 players, one die. Players take turns.
• Rolled values are simply added up
• If you roll a 6, however, the turn ends and the current turn's sum is discarded
• If you decide to stop your turn, the current turn's sum is added to the total
• When a player reaches 50 or more, he has won, unless he was the starting player, in which case the other player can still try to top the result. He has to get to at least one point more, there is no draw. (This adds most complications. The starting player could e.g. try to get to ~60 instead of stopping at 50 - to make a win more likely when the other player stands at 48)

What is the optimal strategy? It obviously depends on the current turn sum. But it also depends on both player's totals.

• Do you mean "When you roll a 6, however, the sum of the current turn is discarded and your turn is ended" otherwise it basically becomes a game of "who is willing to spend more of their life trying to get a high score before passing the dice". Commented May 27, 2020 at 23:55
• I think the solution has already been found. It is referenced in this wikipedia article.
– JS1
Commented May 28, 2020 at 9:57
• I've played this today. Fun little game with the right players, and easy to allow for a third player or experimenting with the rules. In practice, it's a lot about luck and coping with risk. The "optimal" strategy among human players depends quite a bit on the opponent's behaviour, or so it feels. Commented May 28, 2020 at 21:50
• It should not depend on opponent because there is nothing to exploit. Wait, maybe there are exploits in the 'endgame', if you are P2 and know they will stop too early. @JS1 Thanks for the link, I did not know the "name of the game" so could not google.
– user69519
Commented May 30, 2020 at 9:40

In terms of expected value, the optimal strategy is to

roll as long as your total is less than 15.
This is because, if you currently have $$P$$ points pending, the expected value of the next roll is $$\frac{1}{6}(1+2+3+4+5-P)$$.
The expected value of playing this way is just over $$6.15$$ point per turn.

I don't know the strategy for endgames: the probabilities at play look weird enough that calculating the optimal "push" for a given score would have to happen on a case-by-case basis.

• Maximizing the expected value of the next roll is not necessarily the same as maximizing the probability of getting to 50 first, even without the complicated "unless..." rules about who wins. Commented May 28, 2020 at 3:50

Here is programming solution for this problem.

+------------+-------------------------+
| # of Rolls | Expected Turn to Finish |
+------------+-------------------------+
|          1 |                   20.53 |
|          2 |                   12.55 |
|          3 |                   10.14 |
|          4 |                    9.14 |
|          5 |                    8.79 |
|          6 |                    8.66 |
|          7 |                    8.92 |
|          8 |                    9.27 |
|          9 |                    9.52 |
+------------+-------------------------+


The table above shows if you roll

6 times without thinking the outcome of the rolls at the end, your chance to win is the highest with $$8.66$$.

But if we consider stopping rolling after some sum values we got, let's see if something changes or not: https://pastebin.com/mSPgCi9m

I put # as the number of rolls to stop rolling, stop as stopping rolling after some values for your roll you got, and expected values for those.

As a result,

regardless of # of rolls, just roll until you get at least total roll value of $$17$$ then stop rolling, otherwise continue rolling seems the optimal way to play this game, which makes the game to win as expected around $$8.362$$ turn.

with the little tweak as @Jaap Scherphuis suggested, I tried a couple of tricks for the end value where you get close to 50 with some threshold value, and found that having

at least total roll value of $$16$$ then stop rolling, with little tweak where you continue rolling if you are $$47$$, gets us $$8.345$$.

still little improvement though :)

• Let's take an extreme example. Suppose the opponent has a score of 49, your score is 32, and the subtotal for your current turn is 17. Would you really stop to bank those 17 points, giving the opponent a chance to win, or would you go against the strategy and do another roll? Commented May 28, 2020 at 11:45
• @JaapScherphuis you are totally right, a dynamic algorithm would work better than this, I will think about it.
– Oray
Commented May 28, 2020 at 18:55
• It also critically depends on whether you are P1 or P2.
– user69519
Commented May 30, 2020 at 9:44