Submit | All submissions | Best solutions | Back to list |
EIUMERSORT - Merge Sort |
Develop the Merge Sort algorithm on an integer list.
Input
- The first line is an integer N (1 ≤ N ≤ 106), the number of integers.
- The ith line of the next N lines contains the integer (0 ≤ ni ≤ 109).
Output
Output N rows, each row contains the integer in an ascending order.
Sample
Input |
Output |
5 5 4 1 0 3
|
0 1 3 4 5
|
Added by: | Ha Minh Ngoc |
Date: | 2023-06-14 |
Time limit: | 1s |
Source limit: | 50000B |
Memory limit: | 1536MB |
Cluster: | Cube (Intel G860) |
Languages: | CSHARP C++ 4.3.2 CPP CPP14 CPP14-CLANG FSHARP GO JAVA JS-MONKEY NODEJS PHP PYTHON PYPY PYPY3 PYTHON3 RUBY SQLITE SWIFT VB.NET |