#include <iostream>
#include <algorithm>
#include <vector>

using namespace std;

int main(void){
    vector<int> mountains(10);
    for(int i=0;i < 10;i ++)
    {
        cin >> mountains[i];
    }
    sort(mountains.begin(),mountains.end(),greater<int>());
    cout << mountains [0] << endl;
    cout << mountains [1] << endl;
    cout << mountains [2] << endl;

    return 0;
}
