//
//  main.cpp
//  sanpie
//
//  Created by h3037178 on 2017/07/28.
//  Copyright ?? 2017??´ ?????£?????????. All rights reserved.
//

#include <iostream>
#include <algorithm>
using namespace std;
int main(){
    int i[10];
    for(int o=0;o<10;o++){
        cin>>i[o];
    }
    sort(i,i+10);
    cout<<i[9]<<endl<<i[8]<<endl<<i[7]<<endl;
}