#include<iostream>
#include<algorithm>
#include<functional>
using namespace std;
int main(){

	int hill[10];

	for(int i = 0; i < 10; i++) cin >> hill[i];

	sort(hill,hill+10,greater<int>());

	cout << hill[0] << endl << hill[1] << endl << hill[2] <<endl;

	int a;
	std::cin >> a;
return 0;
}