About this document
Optimizing Quick Sort Complexity by Amna Shiekh is a document available to read on EtoBox.
1) The document proposes an algorithm to optimize the worst-case complexity of Quicksort, which is normally O(n^2) but can become O(nlogn). 2) The algorithm calculates the pivot as the average of the maximum and minimum elements of two equally divided subarrays. 3) It then partitions the array based on comparing elements to the pivot. This reduces the number of comparisons compared to traditional Quicksort.
- Author
- Amna Shiekh
- Language
- EN