totup wrote:I would like to know if there is a faster way of verifying my finsihed solution for any 9x9 sudoku puzzle (not by looking at the solution in the back of a book of puzzles ... I may not have the solution if I copied a puzzle from the internet or a magazine). Right now I check it in 3 steps: (1) check that each square has 1-9 (2) check that each row has 1-9 and (3) check that each column has 1-9. I'm wondering if there is a quicker method than this (such as only checking some of the squares, rows, and columns to prove my solution is correct). I've done many puzzles but I'm basically self taught (have not read any books or anything on methods).
I will assume from your posting that you are looking for a method that you can apply by hand. Before giving a method I use, it is not a good idea to talk about squares. Squares can refer to too many different things. Use 'Box' for the 3x3 groupings.
ab wrote:there is no quicker way!
Actually it can be done in 18 checks.
Start in box 1 and look for the 1 digit. Note which row it is in. Now move to box 2 and note which row the 1 is in. Now move to box 3. It can only be in the remaining row.
Repeat the above, for the rest of the digits in boxes 1 to 3.
This proceedure is then repeated in boxes 4 to 6, and then 7 to 9.
All the rows and boxes have now checked. The same proceedure can also be applied to the columns and boxes.
There are some things that can be done to reduce the checks further.
Consider the following band (3 boxes in a row)
- Code: Select all
281 374 569
569 821 347
374 965 812
Note that the digits 1, 2 and 8 are in the first row and box. They are also in the second row and box. (in some order) They must therefore be in the third row and box. (in some order)
The next digits (5, 6 and 9) must also be in the same row and box, whatever the order. Likewise the the third set of digits (3, 4 and 7)
More fequently two of the digits will be paired together - that is same row and box, while the third digit is in the other row for the second and third boxes.
- Code: Select all
732 148 956
416 259 738
895 736 124
Here we see 7 and 3 paired, likewise 1 and 4, also 5 and 9. 2, 6 and 8 each share a row and box with one of the pairs in turn.