This project implements the A* search algorithm to discover the shortest path between two given points. The A* search algorithm is a widely-used pathfinding algorithm known for its efficiency in finding the shortest path between nodes in a graph.
- Download Pygame library on your device
- Run the code on your IDE
- Choose start and end points by making left click on your mouse
- Make obstacles with left click of the mouse
- Delete elements by right click
- Press Space to run the Algorithm
- Press C to clear the screen and start over
To efficiently determine the heuristic value, this project employs the Manhattan Distance calculation method. Manhattan Distance provides a heuristic estimate of the distance between two points in a grid-based system by calculating the sum of the absolute differences between their x and y coordinates.
The project utilizes the following key technologies:
- Priority Queue
- 2D Array
- Set
- Pygame Library
The Pygame library is used for visualization purposes, providing an interactive display of the pathfinding process.
- Explored Nodes (Red)
- Boundary Nodes (Green)
- Start Node (Orange)
- End Node (Pink)
- Shortest Path (Turquois)
- Obstacle Node (Black)
- Empty Node (White)