#include <iostream>
#include <algorithm>

using namespace std;

int main() {
  int h[10];
  for (int i=0; i<10; ++i) {
    cin >> h[i];
  }
  sort(begin(h), end(h));
  cout << h[9] << "\n";
  cout << h[8] << "\n";
  cout << h[7] << "\n";
}
