1.

What is the running time of an unweighted shortest path algorithm whose augmenting path is the path with the least number of edges?(a) O(|E|)(b) O(|E||V|)(c) O(|E|^2|V|)(d) O(|E| log |V|)I have been asked this question in unit test.My doubt stems from Flow Networks in division Flow Networks of Data Structures & Algorithms II

Answer»

Right OPTION is (c) O(|E|^2|V|)

The best I can explain: Each augmenting step takes O(|E|) using an unweighted shortest PATH algorithm YIELDING a O(|E|2|V|) bound on the running time.



Discussion

No Comment Found

Related InterviewSolutions