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