finished merge sort - better way to write this