Dijkstra's Algorithm
Overview
Dijkstra's Algorithm is a classic graph search algorithm used to find the shortest path between nodes in a graph, especially in routing and navigation systems.
Key Steps
- Initialize distances: Set the starting node’s distance to 0 and all others to infinity.
- Visit the closest unvisited node and calculate distances to its neighbors.
- Repeat until the destination node has the smallest distance or all nodes are visited.
Diagram
For more detailed information, visit
Wikipedia: Dijkstra's Algorithm
.