What Is A Merge Sort
What Is A Merge Sort
What Is A Merge Sort
Original input array = N. Auxiliary array for merging = N. Local variables: constant. Function call stack: log N [stay tuned]. Total = 2N + O(log N).
2
N + O(1) for insertion sort and selection sort. In-place = N + O(log N).
Challenge for the bored. In-place merge. [Kronrud, 1969]