#include<iostream>
#include<cstdio>
#include<vector>
#include<algorithm>
#include<functional>
using namespace std;

int main(){
  int mountain[10] = {};

  for(int i=0;i<10;i++){
    scanf("%d",&mountain[i]);
  }
  sort(mountain,mountain+10,greater<int>());
  for(int i=0;i<3;i++){
    printf("%d\n",mountain[i]);
  }


  return 0;
}