Skip to content

miARTre/Maze-solver

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

23 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🧩 Maze Solver

Maze Solver is an educational Python project for drawing and solving mazes using graphics and search algorithms. This project was developed as part of boot.dev courses and is ideal for learning about classes, 2D lists, graphics, and basic algorithms.


✨ Features

  • βœ… Dynamic creation of a grid (maze) with cells
  • βœ… Visualization of walls, entrance, and exit
  • βœ… Gradual drawing of the maze (animation)
  • βœ… Ability to add search and pathfinding algorithms (e.g. DFS, BFS β€” in progress)
  • βœ… Unit tests for logic verification (without graphics)

πŸ› οΈ Project Structure

Maze-solver/
β”‚
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ cell.py         # Class representing a single maze cell
β”‚   β”œβ”€β”€ maze.py         # Class representing the entire maze grid
β”‚   β”œβ”€β”€ main.py         # Main program to run and display the maze
β”‚   β”œβ”€β”€ window.py       # Wrapper for drawing (GUI window)
β”‚   └── tests.py        # Unit tests to verify maze logic
β”‚
β”œβ”€β”€ README.md           # This file
β”œβ”€β”€ .gitignore          # Git ignore rules

πŸ“¦ How to Run

Clone the repository:

git clone https://github.com/miARTre/Maze-solver.git
cd Maze-solver/src

(Optional) Create a virtual environment:
python -m venv venv
source venv/bin/activate  # on macOS/Linux
venv\Scripts\activate     # on Windows

Run the main program (for example, if you have main.py as entry point):
python main.py

βœ… Testing

The project includes basic unit tests for maze logic:

python -m unittest tests.py

The tests do not cover drawing, only logic such as number of cells and wall removal.


🧱 Classes

Cell Represents one maze cell. Stores walls and knows how to draw itself.

Maze Consists of many cells in a grid. Responsible for creating cells, drawing, and breaking walls for entrance/exit.

Window Simple GUI layer for drawing lines and showing animations.


πŸ”§ Work in Progress

Adding maze-solving algorithms (DFS, BFS, A*) Visualizing the path through the maze Interactive random maze generation


πŸ‘¨β€πŸ’» Author

Made with 🧠 by miARTre – part of Boot.dev courses. All comments and pull requests are welcome!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages