Pagini recente » Cod sursa (job #2189468) | Cod sursa (job #507970) | Cod sursa (job #2060482) | Cod sursa (job #703258) | Cod sursa (job #1519848)
#include <fstream>
#include <algorithm>
using namespace std;
ifstream f ( "sort.in" );
ofstream g ( "sort.out" );
const int MAX = 500005;
int Size , myInts [ MAX ] , i;
void read()
{
f >> Size;
for ( i = 1 ; i <= Size ; i ++ )
f >> myInts [ i ];
}
void print()
{
for ( i = 1 ; i <= Size ; i ++ )
g << myInts [ i ] << " ";
}
int main()
{
read();
sort ( myInts + 1 , myInts + Size + 1 );
print();
return 0;
}