01The N-Queens puzzle
Place n queens on an n × n chessboard so that no two attack each other. A queen attacks along its row, its column and both diagonals.
Pure brute force would try every way to put n queens on n² squares: for n = 8 that is about 4.4 billion placements. A first observation cuts this down: two queens can never share a row, so put exactly one queen per row and only choose its column. That leaves nⁿ choices, about 16.7 million for n = 8.
Still, almost all of them are hopeless from the second queen on. If queens 1 and 2 already attack each other, none of the n^(n−2) ways to finish the board (8⁶ for n = 8) can help. The search should notice that and stop.