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