In: Computer Science
Consider the following variation of merge sort: split the list into thirds, sort each third, and then merge all three sorted lists.
(a) Write pseudo-code for this sorting algorithm in python.
(b) Write a recurrence relation for the run-time of this algorithm, and use the master theorem to find the “big O” run time of the algorithm.
(c) How does the run time compare to the usual merge sort? Is this an improvement?
The solution in the images below and let me know of the issues you are facing in the comments below.
The form of master theorem is given below
c) The running time is same as the original merge sort which also has the run time of the order of θ(nlogn) . Hence, it is not an improvement over the ordinary merge sort