#include <iostream>
#include <algorithm>
using namespace std;
int main(){
	int num = 0;
	int mountains[10];
	for (int i = 0; i < 10; i++){
		cin >> mountains[i];
	}
	sort(mountains,mountains+10);
	cout << mountains[9] << endl;
	cout << mountains[8] << endl;
	cout << mountains[7] << endl;
	return 0;
}