Consider a Graph G which contains a negative weight edges but not negative cycles then which of the following statements is TRUE when we run Dijkstra’s algorithm?
- It may not terminate
- It terminates but may produce incorrect results.
Explanation:
It always terminates after |e| relaxations and |v| + |e| priority queue operations, but may produce incorrect results
- It never terminates due to cycles in graph
- None of these