Data Structures and Algorithms
with Object-Oriented Design Patterns in C#![]() ![]() ![]() ![]() ![]() |
In the worst case the i in Equation is always zero.
In this case,
we solve the recurrence using repeated substitution like this:
The worst case occurs when the two subsequences are as unbalanced as they can be--one sequence has all the remaining elements and the other has none.