1.

Floyd Warshall Algorithm used to solve the shortest path problem has a time complexity of __________(a) O(V*V)(b) O(V*V*V)(c) O(E*V)(d) O(E*E)This key question is from Directed Graph topic in section Graph of Data Structures & Algorithms IThe question was posed to me in examination.

Answer»

Right choice is (b) O(V*V*V)

The best explanation: The ALGORITHM uses Dynamic PROGRAMMING and checks for every POSSIBLE path.



Discussion

No Comment Found

Related InterviewSolutions