Real World Maths Busters

The Maths Behind Everyday Life

The story, the formula and a worked example — see exactly where this maths shows up in the world around you.

Back to all stories
Games & Chance 4 min read

Minesweeper Probability Deduction

When logic fails and probability takes over.

A cell showing “3” means exactly 3 of its 8 neighbours are mines. When two numbered cells share neighbours, you can sometimes deduce which cells are safe.

Constraint equations

Each numbered cell gives an equation: the sum of its unknown neighbours equals the number minus known mines.

∑adjxi=n−kknown\sum_{\text{adj}} x_i = n - k_{\text{known}}

A “2” cell with 1 known mine and 3 unknown neighbours

  1. 1

    Step

    x₁ + x₂ + x₃ = 2 - 1 = 1

  2. 2

    Step

    Exactly 1 of the 3 unknowns is a mine

Answer

Each unknown has a 1/3 chance of being the mine

Forced guesses

When constraints don’t uniquely determine any cell, you choose the cell with the lowest mine probability.

P(mine)=remaining minesremaining cellsP(\text{mine}) = \frac{\text{remaining mines}}{\text{remaining cells}}

The formula behind it

Basic Probability

P(A)=favourabletotalP(A) = \frac{\text{favourable}}{\text{total}}
See the full formula, variables and more examples

The takeaway

Minesweeper is constraint satisfaction with a dash of probability when logic runs out.

Back to all stories