Skip to content

Latest commit

 

History

History
 
 

insertion_sort

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

Insertion Sort

Input Format

The input consists of two lines-

  • The first line contains a single integer N
  • The second lines contains N space separated integers which are required to be sorted

Output Format

N space separated integers sorted in non-decreasing order

Sample Input

5
5 2 4 3 1

Sample Output

1 2 3 4 5

Implemented in: