13085 - Merge Sort   

Description

Given an unsorted array. Implement the recursive MergeSort function. In the MergeSort(), you need to call the merge() function implemented in 13084 - Merge Two Arrays.

Input

The first line consists of the size of the array that needs to be sorted.

The second line consists of the elements of unsorted arrray.

Output

The first line consists of the elements of sorted array.

Sample Input  Download

Sample Output  Download

Partial Judge Code

13085.c

Partial Judge Header

13085.h

Tags




Discuss