Intermediate
Data Structures & Algorithms
Q56 / 100
What does Kadane's algorithm solve?
Correct! Well done.
Incorrect.
The correct answer is B) Finding the maximum subarray sum in O(n)
B
Correct Answer
Finding the maximum subarray sum in O(n)
Explanation
Kadane's algorithm uses DP to track the maximum subarray sum ending at each position, updating the global max at each step in a single O(n) pass.
Progress
56/100