#include <bits/stdc++.h>
using namespace std;
int main(){
    ios::sync_with_stdio(false), cin.tie(0);
    vector<int>c;
    for(int i=0;i<10;i++){
        int a;
        cin>>a;
        c.push_back(a);
    }
    sort(c.begin(),c.end());
    cout<<c[c.size()-1]<<endl;
    cout<<c[c.size()-2]<<endl;
    cout<<c[c.size()-3]<<endl;
	return 0;
}

