A unique loop is a closed ring of six or more unsolved cells that share the same two candidates, where every row, column and box the ring passes through holds exactly two of its cells. If every cell in the ring ended up as one of those two digits, you could swap them all and get a second solution. A puzzle with one solution cannot allow that, so at least one cell in the ring must take a different digit, and that lets you remove candidates. It is the unique rectangle stretched past four cells.
Below is a six-cell unique loop from a real master-level puzzle, with the two fillings that make it deadly and the elimination it gives. As with unique rectangles, the ring cells that hold only the pair are called the floor, and the ones with extra candidates are the roof.
- Filling 1
- Filling 2
- Extra 4 in the roof
- 4 removed
The loop and its two fillings
Cells are named by row and column, so R7C2 is row 7, column 2. Walk the ring from R7C2:
- R7C2 to R7C5, along row 7.
- R7C5 to R8C5, down column 5 (both in box 8).
- R8C5 to R8C8, along row 8.
- R8C8 to R9C8, down column 8 (both in box 9).
- R9C8 to R9C2, along row 9.
- R9C2 back to R7C2, up column 2 (both in box 7).
The ring uses rows 7, 8 and 9, columns 2, 5 and 8, and boxes 7, 8 and 9. Each of those nine houses contains exactly two of the six cells, and every cell has 2 and 6 as candidates.
Now fill the ring with only 2s and 6s. Neighbours on the ring share a house, so they must differ, and the digits have to alternate: 2, 6, 2, 6, 2, 6 from R7C2, or 6, 2, 6, 2, 6, 2. Those are the only two ways. In both, each of the nine houses gets one 2 and one 6 from the ring, so every row, column and box contains the same digits either way. Nothing outside the ring can tell the two fillings apart. If a finished grid had only 2s and 6s in these six cells, swapping them would give a second finished grid. That is the deadly pattern.
The ring has to close and have an even number of cells for the alternation to work. With four cells in two rows, two columns and two boxes, it is a unique rectangle. Six is the shortest ring longer than that, and 8 or 10 cells follow the same rule.
The assumption: one solution
This step assumes the puzzle has exactly one solution. Puzzle 201204 does, like every puzzle in the Sudoku Royale library. If you are solving a grid from a source you do not trust, or one you may have copied wrong, the step is not safe: a puzzle with several solutions can really contain the deadly pattern. Our page on whether a sudoku can have multiple solutions covers what that looks like.
With the assumption made, the ring cannot end up as only 2s and 6s. At least one of its six cells must take some other digit.
The elimination: a roof cell must be 4
The floor cells R7C5, R8C5 and R8C8 hold only 2 and 6. They cannot break the pattern. The roof cells R7C2, R9C2 and R9C8 each hold 2, 4 and 6. Their only way out of the pattern is the 4. So at least one of R7C2, R9C2 and R9C8 is a 4.
R9C3 sees all three: R9C2 and R9C8 along row 9, and R7C2 inside box 7. Whichever of them is the 4, R9C3 shares a house with it, so R9C3 is not 4. It drops from 4, 8 and 9 to 8 and 9.
No other cell qualifies. R9C6 also has a 4 and sees R9C2 and R9C8, but it is in box 8 and misses R7C2. R8C3 sees R7C2 and R9C2 in box 7 but misses R9C8. In the actual solution, R9C2 is the 4 and R9C3 is 9.
If you prefer not to rely on uniqueness, this board has another route to the same candidate. A skyscraper on 4 in rows 3 and 7 (R3C3, R3C9, R7C2, R7C9) also removes the 4 from R9C3, using no assumption at all.
What a unique loop can remove
- One roof cell. Every other cell holds only the pair, so the roof cell cannot be either digit of the pair. Remove both from it.
- Several roof cells, one shared extra digit. As in the example: one of the roofs must be that digit, so remove it from every cell that sees all the roof cells.
- Two roof cells in one house. The unique rectangle tricks for a shared house carry over: the extras can form a naked subset with other cells there, or a pair digit locked into the two roofs removes the other pair digit from both roofs. The unique rectangle page walks through those cases on four cells.
How to find a unique loop
- List one pair. Pick two digits, such as 2 and 6, and mark every cell that holds both, with or without extra candidates.
- Walk the ring. From one cell, step to another cell with the pair in the same row, then the same column, and so on, until you return. Count the cells: the number must be even.
- Check every house. Each row, column and box the ring touches must hold exactly two ring cells. A third ring cell in a house breaks the swap.
- Rule out givens. All ring cells must be unsolved at the start. A given cannot be swapped.
- Read the roof. Note the extra candidates and pick the matching case from the list above.
When almost every cell is down to two candidates, also check for BUG+1, which applies the same one-solution idea to the whole board.
Frequently Asked Questions
What is a unique loop in sudoku?
A unique loop is a closed ring of six or more unsolved cells, all holding the same two candidates, where each row, column and box on the ring contains exactly two ring cells. If all of them ended up as the two digits, the digits could be swapped for a second solution, so in a puzzle with one solution at least one ring cell takes another digit.
How is a unique loop different from a unique rectangle?
A unique rectangle is the four-cell case: two rows, two columns, two boxes. A unique loop uses the same deadly-pattern logic on a longer ring of 6, 8 or more cells, spread over more rows, columns and boxes.
Does a unique loop rely on the puzzle having one solution?
Yes. The elimination is only valid if the puzzle has exactly one solution. Puzzles from a reliable source do. On a puzzle that may have several solutions, the deadly pattern can really occur, and the step can remove a correct candidate.
Why must a unique loop have an even number of cells?
Neighbouring cells on the ring share a house, so they must hold different digits of the pair. Going around the ring the digits alternate, and that only works out if the ring has an even number of cells.
Can a unique loop include a given?
No. A given is fixed and cannot be swapped, so a ring with a clue in it is not a deadly pattern.