MergeSort
-
merge method contains a[] --> the final merge array l --> index at 0 m --> indext at middle r --> index at the end
-
the following while loop compare left and right array and put the small number into the final merge array
-
MergeSort method using recursion to divide array into subarray until there is only one element calle the merge method to merge up the arrays