Cod sursa(job #2030884)

Utilizator osiaccrCristian Osiac osiaccr Data 2 octombrie 2017 14:08:12
Problema Sortare prin comparare Scor 60
Compilator cpp Status done
Runda Arhiva educationala Marime 0.39 kb
#include <fstream>
#include <set>
#define DEF

using namespace std;

ifstream fin ("algsort.in");
ofstream fout ("algsort.out");

multiset <int> s;

int main () {
    int n;
    fin >> n;
    for (int i = 1; i <= n; i++) {
        int x;
        fin >> x;
        s.insert (x);
    }
    for (auto it = s.begin (); it != s.end(); it++) {
        fout << *it << " ";
    }

}