#include <iostream>
using namespace std;
int main(void){
  int mountain[10];
  for(int i = 0; i < 10; i++) {
    cin >> mountain[i];
  }
  
  for(int i = 0; i < 9; i++) {
    for(int j = i; j < 10; j++) {
      if(mountain[i] < mountain[j]) {
        int temp = mountain[i];
        mountain[i] = mountain[j];
        mountain[j] = temp;
      }
    }
  }
    
  for(int i = 0; i < 3; i++) {
    cout << mountain[i] << endl;
  }
}