The next Sudoku solution rule I'd like to discuss is the rule of pairs.
Suppose we've been keeping track of pencil marks, and find that two cells in the same row, column, or box can both contain exactly the same two values. Recall that if the pencil marks are accurate, this means that these two values are the only possible values that can go in those cells. Since the cells are “related” – they live in the same group (row, column, or box), they can't each contain the same vale. So one cell must contain one of the values from the pair, and the other cell must contain the other value. Why is this important? Because even though we don't know yet which cell contains which value, we can be sure that none of the other cells in the same group (i.e., row, column, or box) can contain either of the values! We may be able to remove quite a few pencil marks based on this information.
For example, consider the puzzle below:
After performing elimination and finding uniques (pigeonholing), we are faced with this grid:
Take a look at box 9 (the box in the lower-right corner). Notice that two cells in the box contain the pair of values (7, 8). So, we can cross out 7 and 8 from cell (9, 8), and 7 from cells (7, 9) and (9, 9).
Those same two cells also happen to be in the same row, row 7. So we can remove 7s and 8s from row 7, namely the 7 from cell (3,7) and the 8 from cell (6,7).
Here's the new board:
Now there is a new pair: values (1, 4) in cells (9,8) and (9,9). We can remove both values from the rest of box 9 and column 9. Now cell (9,2) has only the value 6 left! We can fill in that value and perform an elimination step:
There is a new pair now, in cells (7,9) and (8,9). In fact, another 22 pencil marks can be removed by the rule of pairs. Finally, we obtain the complete solution:
Hope you enjoyed that! Here are a few grids that can be solved using only the rules I've discussed so far: elimination, uniques, and pairs.
Comments