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

int main(void){
  vector<int>hight;
  int a[10];
 for(int i=0;i<10;i++)
   cin>>a[i];

  for(int i=0;i<10;i++)
    hight.push_back(a[i]);

  sort(hight.begin(),hight.end());

  vector<int>::iterator it = hight.end()-1;

  for(int i=0;i<3;i++){
    cout<<*it<<endl;
    it--;
  }

  return 0;
}