- This Project implements Breadth First path finding algorithm. The algorithm uses FIFO model implemented using queue data structure to find the shortest path. For making the project more fun, and visually appealing I have used pygame python module. You can generate your own maze by just clicking on the box in order to make it behave as an obstacle.
- Once done with your maze hit Spacebar to run the algorithm.
- Also you can generate random maze by hitting the delete key.
This is an example of how you may give instructions on setting up your project locally. To get a local copy up and running follow these simple steps.
- Clone the repo ✔
git clone https://github.com/AKASHCS50/Breadth-First-Path-Finding-Algorithm
- Install pygame ✔
pip install pygame
- Install Tkinter ✔
Tkinter is being used to show pop up message box when no path is found. - Setting up dimentions of maze ✔
Open main.py code and change screen_width on line number 183 and screen_size on 184 to required value
def main():
pygame.init()
screen_size = 500 👈
screen_width = 10 👈
run = True
lock = 0
You are all ready to go 👍
Spacebar - Run Algorithm
Delete - Generate random maze (while window is open).
The algorithm being used is quite slow for bigger sized mazes. Hence extending the project on same model (code) to implement more advanced algorithms like A* and Dijkstra.
Contributions are welcomed.
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated. 🙌🙌
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some Feature'
) - Push to the Branch (
git push origin feature/Feature
) - Open a Pull Request
Akash Sharma: Gmail - Linkedin
Project Link: https://github.com/AKASHCS50/Breadth-First-Path-Finding-Algorithm
MIT © Akash Sharma
✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨