#include <cstdio>
#include <vector>
#include <algorithm>
#include <functional>

using namespace std;

int main(){
    vector<int> val(10);
    
    for(int i = 0; i < 10; ++i){
        scanf("%d", &val[i]);
    }
    
    sort(val.begin(), val.end(), greater<int>());
    
    for(int i = 0; i < 3; ++i){
        printf("%d\n", val[i]);
    }
    
    return 0;
}