Home

(Sigh..) Another Sudoku Solver

Microsoft IE will not display this page correctly
Use e.g. Mozilla, Firefox, Konqueror, Opera, or Safari instead.
 

The sudoku puzzle above is one of the ‘minimal’ sudoku puzzles (only 17 clues) mentioned in the article on sudoku at Wikipedia.org. Solving it by hand is probably ‘beyond hope’ for ordinary mortals; a computer can make short work of it, however.

Move the cursor over the sudoku puzzle to see the solution (this only works in standards-compliant browsers – not in Microsoft IE). I made a program (C source code here) that does it just as fast. A zip file containing the source + an MS-DOS executable (that you can run from a ‘DOS prompt’ in Windows, in XP called a ‘command prompt’ – look under ‘Accessories’) + three sample sudoku puzzles is here. Linux users should just compile the source: cc -O2 -o suds suds.c .

With the optional -m command line switch, the program will continue to find more solutions of the puzzle if they exist (this only happens with badly-constructed puzzles). You can verify that the puzzle used by Sky One in their failed publicity stunt has 1905 solutions.

With the optional -n command line switch, the program will solve the sudoku variant puzzles which appear in the Dutch newspaper NRC-Handelsblad. In those puzzles, an additional constraint is that the numbers in the square (2,2 — 4,4) should all be different (and also in three similarly-placed squares).

Home