merge sort, inversion times