Cod sursa(job #1395017)
Utilizator | Data | 20 martie 2015 22:32:44 | |
---|---|---|---|
Problema | Sortare prin comparare | Scor | 100 |
Compilator | cpp | Status | done |
Runda | Arhiva educationala | Marime | 0.31 kb |
#include <fstream>
#include <algorithm>
using namespace std;
long long f[1000001],k,x;
int main()
{
ifstream fin("algsort.in");
ofstream fout("algsort.out");
fin>>x;
for(k=1;k<=x;k++)
fin>>f[k];
sort(f+1,f+x+1);
for(k=1;k<=x;k++)
fout<<f[k]<<" ";
return 0;
}