2.3.1 - Algorithms (Shortest Path) Flashcards
1
Q
Perform Dijkstra’s on the following graph to find the shortest path between A and H
A
2
Q
Perform A* on the following graph to find the shortest path between A and Z
A
3
Q
What are the key facts about the Dijksktra’s algorithm?
A
- Uses a weight/distance
- Will always visit every node
- Finds the most efficient route
4
Q
What are the key facts about the A* algorithm?
A
- Uses an estimated distance from final node called a heuristic, this helps produce a solution in a faster time.
- Chooses which path to take next based on lowest total distance travelled
- Doesn’t need to find all possible solutions (saves time)