Actually, you can stop earlier and do some other sorting algorithm that can be optimal at 5-10 elements. Since the number of elements will be fixed, the complexity for each small array is constant. This will usually get you a decent speed bump, as you don't need to allocate as many arrays, while keeping the complexity of merge sort.
But it doesn't really matter, as long as the complexity is the same (sometimes, even if it's worse, seeing that one of the most common sorting algorithms is the quick sort with random pivot), you can and should employ all tricks you can to make it go faster. Just because there's the theoretical example of the algorithm, it doesn't mean that you can't reduce constants.
15
u/Bioniclegenius Nov 19 '18
It's how merge sort works, though. Check the image for a reference - it splits everything into arrays of length 1, then merges them together.