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

int main(void)
{
    vector<int> heights;
    for (int i = 0; i < 10; i++)
    {
        int h;
        cin >> h;
        heights.push_back(h);
    }
    sort(heights.begin(), heights.end(), greater<int>());
    for (int i = 0; i < 3; i++)
    {
        cout << heights[i] << endl;
    }
    return 0;
}