Bellman Ford Algorithm

It computes the shortest paths from a single source vertex to all the other vertices in a weighted graph. Vertices are connected via edges, which are associated to a value (called weight or distance). For instance, the set of all the cities and the roads which connect them form a graph. In this context, the Bellman-Ford algorithm would help to find the fastest way to go from a given city to another.