#include <algorithm>
#include <iostream>
#include <vector>

using namespace std;

int main() {
  vector<int> height_of_mountains(10);
  for (int i = 0; i < 10; i++) {
    cin >> height_of_mountains[i];
  }

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

  for (int i = 0; i < 3; i++) {
    cout << height_of_mountains[10 - 1 - i] << endl;
  }
  return 0;
}