Ivars Peterson's MathTrek
March 17, 2003
Sometimes described as poker with dice, Yahtzee is an immensely popular game. Its manufacturer, Hasbro, claims that as many as 100 million people worldwide play the game regularly.
Yahtzee involves rolling five dice with the aim of obtaining favorable scoring combinations. For example, rolling five of a kind scores 50 points, whereas rolling three of kind and a pair (a full house) scores 25 points.
Now, Phil Woodward of Pfizer Global Research and Development in England has solved the gamecomputing all of the more than 1 trillion possible outcomes and working out optimal playing strategies. His results appear in the current issue of Chance.
The object of the game is to throw the largest possible score in each one of 13 defined categories of results, analogous to poker hands. The top score of 50 goes to five of a kind (for example, all five dice showing a six).
Notice that some of the categories have fixed values, whereas other categories have values that depend on the numbers that come up.
In each round, you're allowed a maximum of three rolls of the dice, but you can stop after the first or second roll. You throw all five dice on the first turn. For the second and third turns, you can select some, none, or all of the dice and roll them again. You must then decide in which category you what the final outcome to count, even if that results in a score of 0. Each category is used only once in each game. This means that each game consists of 13 rounds, one for each category.
The awarding of bonus points under certain conditions complicates the scoring. For example, 35 bonus points are awarded if the total score from the first six categories exceeds 62.
"In principle, it is relatively straightforward to solve the game of Yahtzee," Woodward wrote. "There are a finite number of decisions [which dice to roll again and which scoring category to use], all the probabilities associated with the random events (dice rolling) are known, and the utility associated with each decision is well defined (ultimately points are obtained)."
In practice, solving the game means evaluating 1,279,054,096,320 possible outcomes. "Even with a relatively fast PC, it took many computing days to compute the solution," Woodward remarked. Once the solution was computed and stored, a player could then see how well he or she stacked up against the computer's optimal play, dubbed The Solution.
Woodward also noted a number of situations in which the "correct" decision isn't necessarily obvious even to experienced players.
For example, suppose you get either the dice combination 4-4-6-6-6 or the combination 5-5-6-6-6 at the end of the first round. In either case, you could count that combination in the "sixes," "full house," or "three of a kind" category. It turns out that the optimal decision is "full house" for 4-4-6-6-6 and "three of a kind" for 5-5-6-6-6.
"I believe there will be numerous decisions where The Solution offers a slight advantage over even the most experienced Yahtzee player," Woodward concluded.
Interestingly, Woodward's optimal computer player doesn't always win. "There is a considerable amount of luck involved," he wrote. However, "I'm sure the program would beat any human in the long run, but, just like the frequentist statistician, I cannot specify how long is long enough!"
Woodward is not the only one to have solved Yahtzee. Tom Verhoeff and Erik Scheffers of the Eindhoven University of Technology in the Netherlands have also computed all the possibilities, and they have created the "Optimal Solitaire Yahtzee Player" to provide advice to players on the best choice to make in any Yahtzee game situation (see http://wwwpa.win.tue.nl/misc/yahtzee/). Both efforts appear to have come up with the same answers.
Of course, these results apply only for a single player aiming for the best possible score. Other factors come into play when one player competes against another player and has to make decisions that maximize not the score but the probability of a win.
Copyright 2003 by Ivars Peterson
Woodward, P. 2003. Yahtzee : The solution. Chance 16(No. 1):18-22.
Phil Woodward can be reached at email@example.com.
You can play Yahtzee online or download a Java version of the game at http://javaboutique.internet.com/Yahtzee/.
Hasbro provides a brief history of Yahtzee at http://www.hasbro.com/pl/page.corporate_history_yahtzee/dn/default.cfm.
Comments are welcome. Please send messages to Ivars Peterson at firstname.lastname@example.org.
A collection of Ivars Peterson's early MathTrek articles, updated and illustrated, is now available as the MAA book Mathematical Treks: From Surreal Numbers to Magic Circles. Find it at the MAA Bookstore.