Sudoku solver step by step in terminal.
- change the the sudoku in main.cpp to whatever your puzzle is:
Sudoku sudoku(
" 5 8 91 "
" 2 6 "
" 5 13 "
" 9 "
" 7 8 "
"7 5 6 4"
" "
" 9 5176"
"3 4 2 ");
- run
./build.macos.sh
to compile. - run
./a.out
to execute. - either click
a
to see the final result, or clickl
to watch every step. - you can click
h
to go to previous step.
The purpose is to help we human to understand how to solve a Sudoku step by step. So,
- we don't use backstrace searching. We use rule that human can use in real practice.
- we show all possible candidates in the grid.
- we show for what reason some candidates become impossible.