Under construction

Still being built. Things may change

Sort Numbers 2

Time limit2sMemory limit256 MB

Summary
Read up to one million distinct integers and print them in ascending order.
Level

Easy2 of 10

Topics
Sorting, Implementation
Solved
No attempts yet

Problem

You are given N integers. Write a program that prints them in ascending order.

Input

The first line contains the number of integers N. (1 <= N <= 1,000,000)

Each of the next N lines contains one integer. The absolute value of each integer is at most 1,000,000, and all given integers are distinct.

Output

Print the sorted integers in ascending order, one per line, starting from the first line.

Examples1

  1. Example 1

    Input
    5
    5
    4
    3
    2
    1
    
    Expected output
    1
    2
    3
    4
    5