Productivity and Utilities

24 Game Solver

Enter four whole numbers to list every expression that reaches 24.

Your numbers

A whole number from 0 to 99.

A whole number from -1000 to 1000. The classic game uses 24.

Result

Distinct solutions

3

Ways to make 24 from 4, 7, 8, 8.

Numbers
4, 7, 8, 8
Target
24
Distinct solutions
3
Simplest solution
7 x 8 - 4 x 8 = 24

All solutions

No.Expression
17 x 8 - 4 x 8 = 24
24 x (7 - 8 / 8) = 24
38 x (4 + 7 - 8) = 24
How this was calculated
  1. The solver tries every pair of numbers with +, -, x and /, replaces the pair with the result, and repeats until one number is left, using exact fractions so 8 / 3 is never rounded.
  2. Two answers that differ only by the order of added terms or multiplied factors count as one, so 4 + 8 and 8 + 4 are the same solution.
  3. Each of the four numbers must be used exactly once. Parentheses are shown only where they are needed, and the shortest forms are listed first.
  • Division by zero is never allowed. A solution may pass through a fraction on the way, as in 8 / (3 - 8 / 3) = 24.

Calculated using SumPanda.com · https://sumpanda.com/twenty-four-game-solver/

Results are estimates for general information. Verify important figures before relying on them.

Next step

How to use the 24 game solver

  1. Enter four whole numbers from 0 to 99. The classic game uses cards from 1 to 13.
  2. Leave the target at 24, or enter another whole number.
  3. Read the number of distinct solutions and the simplest one.
  4. Scroll the table for the full list, and download it if you want to keep it.

Formula

Pick two numbers a and b and replace them with a + b, a x b, a - b, b - a, a / b or b / a

Repeat on the three numbers, then the two, until one number is left

Keep the expression if the last number equals the target

All arithmetic uses exact fractions, so a result such as 8/3 is never rounded

Division by zero is skipped. Two answers that differ only in the order of added terms or multiplied factors are counted as one.

Hands that are easy, tricky and impossible

4, 7, 8, 8 has 3 distinct solutions, including 4 x (7 - 8 / 8) = 24. 3, 3, 8, 8 has just one, 8 / (3 - 8 / 3) = 24, which only works through a fraction. 5, 5, 5, 1 also has one, 5 x (5 - 1 / 5) = 24.

1, 1, 1, 1 cannot make 24 at all, and neither can 7, 7, 7, 7. Of the 1,820 different hands of four cards from 1 to 13, 1,362 can make 24. 1, 2, 3, 4 has 4 solutions to make 24 and 18 to make 10.

How the game is played

In the 24 game you are dealt four numbers and must combine all of them, each exactly once, with addition, subtraction, multiplication and division and any parentheses to make 24. It is a popular mental arithmetic game because some hands have only a single, surprising answer that goes through a fraction. The solver lets you check a hand, or find out whether a hand is a dead end.

Other puzzle helpers are the Kakuro and Killer Sudoku combination finder, the sudoku solver and the magic square generator. For dice games see the dice pool calculator.

Counting distinct solutions

A full search finds many expressions that are really the same, such as 4 + 8 and 8 + 4, or (a + b) + c and a + (b + c). The page writes each answer in a standard order and lists it once. Different arrangements like a x (b + c) and a x b + a x c remain separate, since they are different calculations. The simplest listed answer is the one with the fewest parentheses.

Assumptions and limits

  • Each of the four numbers is used exactly once, with the operations plus, minus, times and divide only.
  • Numbers are whole numbers from 0 to 99, and the target is a whole number from -1000 to 1000.
  • Intermediate fractions are allowed, and division by zero is not.
  • Powers, roots, concatenating digits and other tricks are not used.

Formulas reviewed October 10, 2026. See the calculation methodology for how SumPanda rounds, tests and sources its formulas.

Frequently asked questions

How do I solve the 24 game?

Combine two numbers at a time with +, -, x or /, and repeat. The solver tries every choice and lists the ones that end at 24.

Can every set of four cards make 24?

No. Of the 1,820 hands of four cards numbered 1 to 13, 1,362 can make 24, about 75 percent.

Why are fractions allowed in the middle?

Some hands only work that way. For 3, 3, 8, 8 the answer is 8 / (3 - 8 / 3) = 24, with 3 - 8/3 = 1/3 on the way.

Can I use a different target?

Yes. Enter any whole number from -1000 to 1000 and the solver lists the ways to reach it from the four numbers.