formatting mergesort