The Floyd-Warshall algorithm is a popular method for solving the All-Pair…
Bihar STET · PGT (Paper 2) · Computer Science · 2023
The Floyd-Warshall algorithm is a popular method for solving the All-Pair Shortest Paths problem. What is the time complexity of the Floyd-Warshall algorithm for a graph with "n" vertices?
- A.
O(n)
- B.
O(n log n)
- C.
O(n^2)
- D.
O(n^3)
Attempted by 17 students.
Show answer
Correct answer: D
Explore the full course: Bihar Stet Paper Ii Computer Science
Loading lesson…