#include <iostream>
#include <array>
#include <algorithm>
using namespace std;

int main() {
  array<int,10> a;
  for(int &i: a) cin >> i;
  sort(a.begin(),a.end(),greater<int>());
  for(int i: {0,1,2}) cout << a[i] << endl;
  return 0;
}