Pagini recente » Cod sursa (job #2804449) | Cod sursa (job #713027) | Cod sursa (job #3244018) | Cod sursa (job #1694252) | Cod sursa (job #1471784)
#include <iostream>
#include <stdio.h>
#include <vector>
#include <algorithm>
#define NMax 500005
using namespace std;
vector<int> v;
int N,x;
int main()
{
freopen("algsort.in","r",stdin);
freopen("algsort.out","w",stdout);
scanf("%d",&N);
for(int i=1;i<=N;i++)
{
scanf("%d",&x);
v.push_back(x);
}
sort(v.begin(),v.end());
for(vector<int>::iterator it=v.begin();it!=v.end();it++)
printf("%d ",*it);
}