#include <bits/stdc++.h>
using namespace std;

int main(){
  vector<int> mount(10,0);
  
  for(int i = 0; i < 10; i++){
    cin >> mount.at(i);
  }
  sort(mount.begin(), mount.end());
  cout << mount.at(9) << endl << mount.at(8) << endl  << mount.at(7) << endl;
}
