X-wing
What it is
The X-wing is the first technique that looks at one digit across several rows and columns at once. It works like this.
Pick a digit. Find two rows where that digit can only go in two cells each. If, in both rows, those two cells are in the same two columns, the four cells form a rectangle. The digit must go in two opposite corners of that rectangle: either top left and bottom right, or top right and bottom left. That diagonal shape is where the name comes from.
Either way, each of the two columns gets its copy of the digit from one of these two rows. So no other cell in those two columns can hold the digit. You can remove it from the rest of both columns.
It works the other way round too: two columns where the digit is limited to the same two rows lets you remove the digit from the rest of those two rows.
How to spot it
Choose one digit and look only at that digit’s candidates. For each row, count how many cells it could go in. Make a note of any row where the answer is exactly two. Then compare those rows: do any two of them have their candidates in the same pair of columns?
Do the same for columns, looking for two columns where the digit is limited to the same two rows.
It helps to look at one digit at a time and ignore everything else. The rectangle then stands out.
A worked example
Take the digit 5. After looking along every row, you find:
- In row 2, 5 can only go in column 3 or column 7.
- In row 6, 5 can only go in column 3 or column 7.
These four cells (row 2, column 3; row 2, column 7; row 6, column 3; row 6, column 7) form a rectangle.
Think it through. If row 2’s 5 is in column 3, then column 3 already has its 5, so row 6’s 5 must be in column 7. If row 2’s 5 is in column 7, row 6’s 5 must be in column 3. In both cases, column 3 gets its 5 from row 2 or row 6, and so does column 7.
So no other cell in column 3 or column 7 can be 5. If row 4, column 3 and row 9, column 7 both had 5 noted, remove it from both. Say row 9, column 7 had notes of 1 and 5. After removing the 5, only 1 is left, so you can place it.
Why it works
The two rows each need a 5. Each row only has two places for it, and those places are in the same two columns. Two rows, two columns, two 5s: they have to pair up, one in each column. That uses up both columns’ 5s, leaving none for anywhere else in those columns.
A common mistake
The most common mistake is removing the digit from the wrong lines. If you find the pattern by looking at rows, you remove the digit from the columns. If you find it by looking at columns, you remove it from the rows. The lines where the digit is limited to two cells are the ones that define the pattern. The other lines are where the eliminations happen.
Another mistake is using rows where the digit has three possible cells. That breaks the pattern, unless you are looking at a swordfish, which is the bigger version of the X-wing.
When you will need it
X-wings are part of the Hard toolkit on sudoku.ie, alongside triples and quads. You will meet them on Thursday and Friday, and on Saturday’s Expert puzzle. Once you are comfortable with X-wings, the swordfish and jellyfish follow the same idea with three and four lines.