merge sort on two already sorted subarrays