How does the knight's tour work?
A chess knight moves in an L: two squares one way, then one to the side, jumping over anything in between. Pick a starting square, then tap one of the highlighted squares each turn. The aim is to land on every square of the board exactly once. Undo steps back; if no jumps are left, you can undo or end there.
Your result is how many squares you visited, out of 25, 36 or 64. A full tour is complete; if its last square is a knight's jump from the first, it is a closed tour, which could start again at once.
Is a knight's tour always possible?
On a 6 × 6 or 8 × 8 board, yes, from every square. On 5 × 5 only from 13 of the 25 squares: the ones the same colour as the corners. A knight changes colour on every jump, and 25 squares means 13 of one colour and 12 of the other, so a tour must start and end on the colour with 13.
There are 1,728 different tours on a 5 × 5 board: 304 from each corner, 64 from the centre and 56 from each of the other squares of that colour. The site's tests count them, and find a tour from every square the game lets you start on.
How do you solve a knight's tour?
Use Warnsdorff's rule: always jump to the square that has the fewest onward jumps left. It was first described by H. C. von Warnsdorff in 1823. It is a rule of thumb, not a guarantee: when it leads into a dead end, step back and try the next-best square. In practice it means visiting the corners and edges early, while you still can, and saving the well-connected middle for later.
- Never leave a corner behind. A corner has only two jumps in and out; skip it and it is lost.
- Count before you jump. Of the squares you can reach, pick the one with the fewest ways on.
- Start small. 5 × 5 takes a few minutes; 8 × 8 takes patience.
Who first studied the knight's tour?
The puzzle is old: a pattern of a knight's tour on half a board appears as a verse form in Rudrata's Kavyalankara, a Sanskrit work on poetry from the 9th century. Leonhard Euler was among the first mathematicians to study it, in 1759. Today it is a classic exercise in computer science: finding a path that visits every point of a network once.
For real chess positions, try the Chess Puzzles; for another one-path puzzle, the One Line Puzzle.