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