#include <iostream>
using namespace std;

int main()
{

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

	for (int i = 0; i < 10; i++) {
		for (int j = i + 1; j < 10; j++) {
			if (hill[i] < hill[j]) {
				int tmp = hill[i];
				hill[i] = hill[j];
				hill[j] = tmp;
				//cout << "ALICE!" << endl;
			}
		}
	}

	//cout << endl << endl;

	for (int i = 0; i < 3; i++) {
		cout << hill[i] << endl;
	}

	//cin >> hill[1];
    return 0;
}