Bellman-Ford vs Dijkstra: Under what circumstances is Bellman-Ford better?

Bellman-Ford algorithm is a single-source shortest path algorithm, so when you have negative edge weight then it can detect negative cycles in a graph. The only difference between the two is that Bellman-Ford is also capable of handling negative weights whereas Dijkstra Algorithm can only handle positives. From wiki However, Dijkstra’s algorithm greedily selects the … Read more