Merge sort is now working fine