#include <bits/stdc++.h>
using namespace std;

#define REP(i, x) for (int i = 0; i < (int)(x); i++)
#define REPS(i, x) for (int i = 1; i <= (int)(x); i++)

int main(int argc, char *argv[])
{
    ios::sync_with_stdio(false);
    cin.tie(0);
    cout.tie(0);

    vector<int> p(10);

    REP(i, 10)
    {
        cin >> p[i];
    }

    sort(p.begin(), p.end(), greater<int>());

    REP(i, 3)
    {
        cout << p[i] << endl;
    }

    return 0;
}
