Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/anuraganalog/rat-in-a-maze
Solve the famous problem rat in a maze using DFS
https://github.com/anuraganalog/rat-in-a-maze
cheese colors dfs finding gui maze path pillow py python3 rat rat-in-a-maze stack tkinter-gui
Last synced: 14 days ago
JSON representation
Solve the famous problem rat in a maze using DFS
- Host: GitHub
- URL: https://github.com/anuraganalog/rat-in-a-maze
- Owner: AnuragAnalog
- License: gpl-3.0
- Created: 2019-12-10T16:27:54.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2022-10-15T19:23:39.000Z (about 2 years ago)
- Last Synced: 2024-12-14T11:41:56.346Z (20 days ago)
- Topics: cheese, colors, dfs, finding, gui, maze, path, pillow, py, python3, rat, rat-in-a-maze, stack, tkinter-gui
- Language: Python
- Size: 2.39 MB
- Stars: 3
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Rat in a Maze
## Problem Statement
There will be a maze of size nxn, with walls at random position with random shape. The source will be at the top left, and the destination will be at the bottom right.
> Source and Destination Positions can be customizedThe task is to find the cheese which is at the destination from the source.
**Priority**
right -> down -> left -> up
## Implementation
**Language Used:**
Python3**Data-Structure Used:**
Stack(Linked list)
> In this, stack is implemented using list(append and pop)**Traversal Method:**
Depth First Search(DFS)**Modules Used**
* Time
* Numpy
* Termcolor
* **Gui Modules**
* Tkinter
* Pillow
## Setup
Before running the file, see that you have installed all the packages
sudo pip3 install -r requirements.txt
and
sudo apt install python3-tk
## Demo
**Found a Path**
![Found a path](./just_a_demo-there_is_path.gif)
**No Path**
![No path](just_a_demo-no_path.gif)
## Miscellaneous
You can even change the colors of the maze; they are customizable
./colors.py
The above program, displays all the possible colors in tkinter.