#include<cstdio>
#include<string>
#include<iostream>
#include<algorithm>
#define _USE_MATH_DEFINES
#include<math.h>
#include<queue>
#include<set>
#include<vector>
#define INF 100000000

#define MAX_N 100

typedef long long int ll;
using namespace std;


int main(){

	int mountain[10];

	for(int i = 0; i < 10; i++){
		scanf("%d", &mountain[i]);
	}

	for(int i = 0; i < 10; i++){
		for(int j = i+1; j < 10; j++){
			if(mountain[i] < mountain[j]){
				int kari = mountain[i];
				mountain[i] = mountain[j];
				mountain[j] = kari;
			}
		}
	}

	for(int i = 0; i < 3; i++){
		printf("%d\n", mountain[i]);
	}

	return 0;

}