Question: In class we saw an algorithm for computing the kth smallest number in a given list of n numbers in time O(n). The algorithm worked

In class we saw an algorithm for computing the kth smallest number in a given list of n numbers in time O(n). The algorithm worked by breaking the numbers into n/5 sets of size 5, and the then considering the medians of these sets. We set w to be the median of these medians, and used it to split all the numbers and recurse. What bound would you obtain if you analyzed the algorithm that uses sets of size 4 in the above process? (The median of 4 numbers a1 a2 a3 a4 is (a2+a3) / 2 ).

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!