McqMate
Q. |
What is the time complexity of Kadane’s algorithm? |
A. | o(1) |
B. | o(n) |
C. | o(n2) |
D. | o(5) |
Answer» B. o(n) | |
Explanation: the time complexity of kadane’s algorithm is o(n) because there is only one for loop which scans the entire array exactly once. |
View all MCQs in
Design and Analysis of AlgorithmsNo comments yet