We usually want to know the shortest/fastest route between two points. This is a well-known problem in graph theory. There are several algorithms that solve this problem: A*, Dijkstra, etc.
I have implemented in C++ those algorithms and a graph of the roads in California.
This is very important in Dijkstra’s based algorithm because we need to calculate the minimum value in a list, so we try to avoid that with a tree search.
The heap optimization fastens the algorithm x1000.
Source Code: https://github.com/dani2442/PathFinder