Skip to content

A Sudoku game that checks if you are right by using backtracking algorithm to solve the board.

Notifications You must be signed in to change notification settings

yuvalco/Sudoku-game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Introduction

This is a simple Sudoku solver application developed as a personal project. The application is written in Python and uses the backtracking recursion algorithm to solve Sudoku puzzles. It provides a user-friendly graphical user interface (GUI) for users to input and solve Sudoku puzzles.

Features

Sudoku Solver: The application can solve standard 9x9 Sudoku puzzles using the backtracking algorithm, ensuring a valid and complete solution.

Interactive GUI: Users can interact with the Sudoku solver through a graphical user interface, making it easy and intuitive to input and solve puzzles.

Demonstration of backtracking

gif

GUI.py

Contains everything related to the UI. Includes a class called Grid that contains an instance of each cube on the board. The main() function is found here.

Cube.py

Contains one class Called Cube.
Each "cube" or cell on the board has it's own value, bounds, and other properties.

Sudoku.py

This file has no classes, only functions.

solve_board(board)

Solves a given board using the backtracking algorithm that checks every possible outcome until it finds a valid one.

valid(board, location, value)

Checks whether a given value in a specific location is valid for a given board.

find_empty_space(board)

Searches for empty location on the board.

Images

Board

image1

Board with selected cube and some values filled in.

image2

About

A Sudoku game that checks if you are right by using backtracking algorithm to solve the board.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages