#include<bits/stdc++.h>

using namespace std;

int main(){
    vector<int> v;
    for(int i=0;i<10;i++){
    	int x;
    	cin >> x;
    	v.push_back(x);
    }
    sort(v.begin(),v.end());
    cout << v[9] << endl;
    cout << v[8] << endl;
    cout << v[7] << endl;
}

