Home / Engineering / Design and Analysis of Algorithms / Question

M

Mr. Dubey • 51.62K Points
Coach

Q.) What is the running time of the Floyd Warshall Algorithm?

(A) big-oh(v)
(B) theta(v2)
(C) big-oh(ve)
(D) theta(v3)
Correct answer : Option (D) - theta(v3)

Explanation:
 the running time of the floyd warshall algorithm is determined by the triply nested for loops. since each execution of the for loop takes o(1) time, the algorithm runs in time theta(v3).

Share

Discusssion

Login to discuss.