This is a Python program that solves Sudoku puzzles using a backtracking algorithm. It provides a sudoku_solver function that takes a 9x9 Sudoku puzzle as input and attempts to solve it.
To use the Sudoku Solver, you need to call the sudoku_solver function and provide a 9x9 puzzle as a list of lists. Each inner list represents a row, and the numbers in the puzzle should be represented as integers. Empty cells are denoted by the number 0.
if __name__ == '__main__':
puzzle = [[0, 0, 0, 7, 0, 2, 9, 0, 0],
[0, 9, 0, 0, 8, 1, 2, 0, 9],
[8, 7, 2, 4, 5, 0, 0, 1, 3],
[1, 0, 0, 0, 7, 0, 4, 2, 0],
[9, 0, 0, 1, 0, 5, 0, 0, 8],
[0, 4, 0, 0, 0, 0, 5, 6, 0],
[0, 3, 5, 8, 0, 4, 0, 9, 6],
[0, 8, 0, 0, 3, 6, 7, 0, 0],
[0, 0, 0, 5, 0, 0, 0, 3, 2]]
sudoku_solver(puzzle)