Pagini recente » preoni2007_runda2_1112 | Statisticile problemei Yamstp | Cod sursa (job #27898) | Statisticile problemei TollRoads | Cod sursa (job #3294232)
#include <bits/stdc++.h>
using namespace std;
ifstream fin("algsort.in");
ofstream fout("algsort.out");
const int nMax = 5e5;
int n;
vector<int> v(nMax);
int main()
{
ios::sync_with_stdio(false);
fin.tie(nullptr);
fin >> n;
for(int i = 0; i < n; ++i)
{
fin >> v[i];
}
sort(v.begin(), v.begin() + n);
for(int i = 0; i < n; ++i)
{
fout << v[i] << " ";
}
fin.close();
fout.close();
return 0;
}