I think you need to get your facts right. You can refer to this article fromGFG. Dijkstra may work in some cases where there is a negative edge but not in all of them. Eg : Consider a loop like this in a graph with three nodes A, B and C : A->B->C->A. Assume : A -> ...