added merge sort impl