X-Wing is the first and easiest method in the “Wings” family of strategies. It is also the first slightly harder method that we will consider,
but searching for it is not too difficult, because we only restrict the search to a single candidate in a well-defined setting.
Let us jump straight into the first example. Let us closely examine the cells E4, E8, H4 and H8.
These cells form a rectangle and all contain the candidate 9. What is more, the 9s in row E are locked, i.e.
these are the only two such candidates in row E. The same is true for row H. Let us select the cell E4
(marked in light-green) and check the two possibilities - either it has a value of 9 or some other value.
Let us sum up the elimination rule, explained above. If four cells are arranged in a
rectangle, contain a given candidate and the two rows (forming the square)
contain only the candidate only twice, then we can eliminate the corresponding candidate from other cells in the two columns (forming the square).
Like other methods, X-Wing also works when we reverse the rows and columns.
In this next example we observe the same pattern, but this time, the candidates are locked with regards to columns and we will eliminate from rows.
The X-Wing is formed by cells B1, B5, E1 and E5 which form the rectangle. In column 1 the candidate 4 is present only in B1 and E1. The same is true column 5 with regards to B5 and E5. Hence, the pairs {B1, E1} and {B5, E5} are locked. By the same logic as in the previous example, if B1 is 4, then E5 is forced to be 4 (the other two cells are not 4). If B1 is not 4, then B5 and E1 are forced to be 4. In any case the candidate 4 is present either in the light-green cells or in the orange cells, but we do not know in which pair. What we know is that the candidate 4 cannot be the true value of B2 and can be eliminated from that cell.
Let us sum up the X-Wing strategy. If there are four cells containing a specific candidate, arranged in a rectangle and the cells are 2x2 locked by rows/columns, then we can eliminate the candidate from the corresponding columns/rows of the rectangle.