Sudoku Solving Techniques

XY-Wing

The XY-Wing technique involves three cells, and each of them has two candidate digits. Because these three cells are not necessarily very close to each other, it is not very easy to observe the pattern of this technique. Below, we will demonstrate this technique in three different situations.

1. XY-Wing (Row-Column)

Consider the following partial Sudoku puzzle:

XY

XZ

YZ

Figure 1a: XY-Wing (Row-Column) Pattern

The XY-Wing (Row-Column) pattern is shown in Figure 1a. The XY-Wing technique involves three cells. Each of these three cells has two candidates. The pink cell (the pivot) has two candidates X and Y. One of the yellow cells with candidates X and Z has a common candidate X with the pink cell, and the two cells share the same row. The other yellow cell with candidates Y and Z has candidate Y in common with the pink cell, and these two cells share the same column. At the same time, the two yellow cells have a common candidate Z. These three cells together form an XY-Wing (Row-Column) pattern.

XY

XZ

YZ

Z

Figure 1b: The Orange Cell Cannot be Z

There are two possibilities, X and Y, for the pink cell. Let's see what happens to the orange cell in these two cases.

  1. If the pink cell is X, then the XZ yellow cell in the same row as the pink cell cannot be X and therefore must be Z. As a result, the orange cell cannot be Z since it is in the same column as the XZ yellow cell, which is Z in this case.
  2. If the pink cell is Y, then the YZ yellow cell in the same column as the pink cell cannot be Y and therefore must be Z. Again, the orange cell cannot be Z since it is in the same row as the YZ yellow cell, which is Z in this case.

So, in either case, the orange cell* cannot be Z. If there is a candidate Z in the orange cell, it can be removed, as shown in Figure 1b.

Example for the XY-Wing (Row-Column) technique in a real Sudoku puzzle

2. XY-Wing (Block-Row)

XY

YZ

XZ

Figure 2a: XY-Wing (Block-Row) Pattern

The pink cell (the pivot) has two candidates, X and Y. The yellow cell with candidates Y and Z shares a common 3x3 block with the pink cell, and the two cells have a common candidate Y. The other yellow cell with candidates X and Z shares a common row with the pink cell, and the two cells have a common candidate X. Also, the two yellow cells have a common candidate Z. These three cells together form an XY-Wing (Block-Row) pattern.

Z

XY

Z

YZ

XZ

Z

Z

Z

Figure 2b: All Orange Cells Cannot be Z

There are two possibilities, X and Y, for the pink cell. Let's see what happens to the orange cells in these two cases.

  1. If the pink cell is X, then the XZ yellow cell in the same row cannot be X and therefore must be Z. As a result, all the orange cells cannot be Z since they are in the same row or in the same block as the XZ yellow cell, which is Z in this case.
  2. If the pink cell is Y, then the YZ yellow cell in the same block cannot be Y and therefore must be Z. Again, all the orange cells cannot be Z since they are in the same row or in the same block as the YZ yellow cell, which is Z in this case.

In either case, all the orange cells* cannot be Z. If there are candidate Z's in the orange cells, they can be removed, as shown in Figure 2b.

Example for the XY-Wing (Block-Row) technique in a real Sudoku puzzle

3. XY-Wing (Block-Column)

XY

YZ

XZ

Figure 3a: XY-Wing (Block-Column) Pattern

The pink cell (the pivot) has two candidates X and Y. The yellow cell with candidates Y and Z shares a common 3x3 block with the pink cell, and the two cells have a common candidate Y. The other yellow cell with candidates X and Z shares a common column with the pink cell, and the two cells have a common candidate X. Also, the two yellow cells have a common candidate Z. These three cells together form an XY-Wing (Block-Column) pattern.

Z

XY

YZ

Z

Z

Z

XZ

Z

Figure 3b: All Orange Cells Cannot be Z

There are two possibilities, X and Y, for the pink cell. Let's see what happens to the orange cells in these two cases.

  1. If the pink cell is X, then the XZ yellow cell in the same column cannot be X and therefore must be Z. As a result, all the orange cells cannot be Z since they are in the same column or in the same block as the XZ yellow cell, which is Z in this case.
  2. If the pink cell is Y, then the YZ yellow cell in the same block cannot be Y and therefore must be Z. Again, all the orange cells cannot be Z since they are in the same column or in the same block as the YZ yellow cell, which is Z in this case.

In either case, all the orange cells* cannot be Z. If there are candidate Z's in the orange cells, they can be removed, as shown in Figure 3b.

Example for the XY-Wing (Block-Column) technique in a real Sudoku puzzle

* The orange cells are those cells falling in the common related area of both yellow cells. That means the orange cells are in the same row, the same column, or the same 3x3 block as each of the two yellow cells.

List of Sudoku Solving Techniques

Previous: Hidden Quad

Next: XYZ-Wing

©2025 sudoku9x9.com - All Right Reserved.