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

int main()
{
    int A[10];
    for (int i = 0; i < 10; i++) {
        cin >> A[i];
    }
    sort(A, A + 10);
    cout << A[9] << endl << A[8] << endl << A[7] << endl;
    return 0;
}