#include<iostream>
#include<array>
#include<algorithm>

using namespace std;

int main(){
    array<int, 10> mountain_height;
    for(int i = 0; i < 10; i++){
        cin >> mountain_height[i];
    }
    sort(begin(mountain_height), end(mountain_height));
    for(int i = 0; i < 3; i++){
        cout << mountain_height[9-i] << endl;
    }
    return 0;
}