What is the time complexity of the Divide and Conquer algorithm for finding the maximum and minimum elements in an array of size "n"?
Show answerHide answer
Correct answer: (A) O(n)
Explanation
The divide-and-conquer MaxMin algorithm makes about 3n/2 - 2 comparisons; T(n) = 2T(n/2) + 2 solves to O(n).