Logic

Nonograms Are Pixel Art You Solve With Arithmetic

How to read the clue numbers, where beginners stall, and three techniques that unlock harder grids.

Nonograms Are Pixel Art You Solve With Arithmetic
A nonogram half solved, with the overlap rule doing the work. Illustration: PuzzleMakers

A nonogram looks like a crossword that has lost its words. A rectangular grid, a column of numbers down the left, a row of numbers across the top, and no letters anywhere. Fill the right cells and a picture appears. Fill the wrong ones and you get nothing, because unlike a crossword there is no partial credit and no way to bluff.

The format goes by several names - Picross, Griddlers, Hanjie - and was popularised in Japan in the late 1980s. Its origin story involves two independent inventors and a magazine competition, which is a very nonogram sort of history.

Reading the clues

Each number sequence describes the runs of filled cells in that row or column, in order, separated by at least one empty cell.

A row clue of 4 in a ten-wide grid means one unbroken run of four filled cells somewhere in those ten. A clue of 3 1 means a run of three, then at least one gap, then a single cell, in that order. A clue of 1 1 1 means three isolated cells with gaps between them.

That is the entire rule set. Everything else is deduction.

Technique one: the overlap

This is the technique that turns a nonogram from guesswork into arithmetic, and it is the one beginners most often miss.

Take a row ten cells wide with a clue of 7. Push the run as far left as it will go: it occupies cells 1 to 7. Push it as far right as it will go: cells 4 to 10. Cells 4, 5, 6 and 7 are filled in both cases, so they are filled in the answer, regardless of where the run actually sits.

The general form: for a single run of length n in a line of length L, the overlap is 2n - L cells in the middle. Any time a run is longer than half the line, you get free cells. This works for multi-run clues too, by packing everything left, packing everything right, and comparing.

Every nonogram opens with the same move: find the lines where the numbers barely fit, and take the overlap.

Technique two: edge forcing

Once you have a single confirmed filled cell near the start of a line, the first run is often pinned. If a row clue starts with 5 and you know cell 2 is filled, the run must include cell 2, so it starts no later than cell 2 and no earlier than cell 1 - which means cells 2 through 5 are filled either way.

The same logic runs from a confirmed empty cell. A known blank at cell 4 in a row clued 6 means the run cannot span the blank, so it sits entirely in cells 5 onwards, which usually forces most of it immediately.

Technique three: line completion

When the sum of a line's clue numbers plus the mandatory single gaps equals the line length exactly, the line is fully determined. A ten-wide row clued 4 3 1 needs 4 + 1 + 3 + 1 + 1 = 10 cells, so there is exactly one arrangement. Scan for these first; they are free.

This is also the constructor's main tool for controlling difficulty. Give a grid several exactly-determined lines and it opens easily. Give it none and the solver has to start with overlaps, which is a noticeably harder entry point.

Related: the guarantee that makes all of this work is uniqueness, which we cover in how a puzzle proves it has exactly one solution. For a different family of deduction puzzle, see logic grid puzzles and the zebra problem.

Where beginners stall

Three places, reliably.

  • They do not mark empties. A confirmed empty cell is as informative as a confirmed filled one, and refusing to mark them throws away half the information in the grid.
  • They guess. A well-made nonogram never requires it. If you are guessing, there is a deduction available somewhere else on the board.
  • They work one line at a time. The value of a nonogram is in alternating between rows and columns. Every cell you resolve in a row is a new constraint on a column.

Why the picture matters

The image at the end is not decoration, it is error detection. A half-solved nonogram that is producing a recognisable shape is probably correct; one producing static probably is not. Good constructors exploit this by choosing images with strong silhouettes, and by putting the recognisable part of the picture in the region the solver reaches last.

That is also the argument for solving them on paper at least once. On paper you see the shape emerging in your peripheral vision; in an app the highlighting tends to hide it from you until the end.

If you want to widen out from nonograms, the arithmetic-flavoured deduction puzzles are the natural next step - Kakuro and the killer variants use the same overlap thinking with sums instead of runs - and the Japanese publisher Nikoli, which named and popularised much of this genre, still publishes the reference versions. For a lighter daily deduction habit, a good riddle collection works the same muscle in a smaller format.

MQ
Written by Mara Quill Editor of the PuzzleMakers weekly and a constructor with 60+ published grids. More from Mara Quill →

Keep reading

All Logic →

One good puzzle a week. No filler.

New articles, constructor notes and a fresh mini crossword every Sunday. Free, and easy to leave.