//http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=0001

#include <iostream>
#include <algorithm>
using namespace std;
int main() {
	int d[10] = { 0 };
	for (int i = 0; i < 10;i++) cin >> d[i];
	sort(d, d + 10);
	reverse(d, d + 10);
	cout << d[0] << endl << d[1] << endl << d[2] << endl;
}