#include<iostream>
#include<algorithm>
#include<vector>
using namespace std;

int main()
{
    int n;
    vector<int> v;
    for(int i=0; cin>>n && i<5; i++) v.push_back(n);
    
    stable_sort(v.begin(), v.end());
    reverse(v.begin(), v.end());

    cout << v.at(0);
    for(int i=1; i<5; i++) cout << " " << v.at(i);
    cout << endl;

    return 0;
}