 # Problem of the Week Problem C and Solution Just Sum Dice

## Problem

Ahmik created a game for his school’s carnival where players roll two dice and find the sum of the two numbers on the top faces. If this sum is a perfect square or a prime number, they win a prize. To make it more interesting, Ahmik made the two dice using a 3D printer so that they each have the numbers $$1$$, $$2$$, $$3$$, $$5$$, $$7$$, and $$9$$ on their faces. One of the dice is purple and the other is green.

What is the probability that a player will win a prize after rolling the dice once? Note:
A square of any integer is called a perfect square. The number $$25$$ is a perfect square since it can be expressed as $$5^2$$ or $$5 \times 5$$.
A prime number is an integer greater than $$1$$ that has only two positive divisors; $$1$$ and itself. The number $$17$$ is prime because its only positive divisors are $$1$$ and $$17$$.

## Solution

To solve this problem, we will create a table showing all of the possible rolls for each die and the corresponding sums.

Green Die 1 2 3 5 7 $$2$$ $$3$$ $$4$$ $$6$$ $$8$$ $$10$$ $$3$$ $$4$$ $$5$$ $$7$$ $$9$$ $$11$$ $$4$$ $$5$$ $$6$$ $$8$$ $$10$$ $$12$$ $$6$$ $$7$$ $$8$$ $$10$$ $$12$$ $$14$$ $$8$$ $$9$$ $$10$$ $$12$$ $$14$$ $$16$$ $$10$$ $$11$$ $$12$$ $$14$$ $$16$$ $$18$$

From the table, we see that there are $$36$$ possible outcomes. We also see that the perfect squares $$4$$, $$9$$, and $$16$$ appear in the table seven times.

The smallest number in the table is $$2$$, and the largest number in the table is $$18$$. The prime numbers appearing in the table in this range of numbers are $$2$$, $$3$$, $$5$$, $$7$$, and $$11$$. These numbers appear in the table a total of nine times.

Thus there are $$7$$ perfect squares and $$9$$ prime numbers in the table. Since a number cannot be both a prime number and a perfect square, we can conclude that there are $$7+9=16$$ sums that are prime numbers or perfect squares.

To determine the probability of a specific outcome, we divide the number of times the specific outcome occurs by the total number of possible outcomes. Thus, the probability of a player rolling a sum that is either a prime number or a perfect square is $$16\div 36=\frac{4}{9}\approx 44\%$$. Therefore, a player has approximately a $$44\%$$ chance of winning a prize after rolling the dice once.

Extension: A game is considered fair if the chance of winning is $$50\%$$. How could you change the rules of this game to make it fair?