mergeSort works