#include <iostream>
using namespace std;

int main(void)
{
	unsigned h[10];
	int c = 0;

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

	do{
		int i = c;
		c = 10;
		for(int j = 9; j > i; j--) {
			if(h[j] > h[j - 1]) {
				unsigned tmp = h[j];
				h[j] = h[j - 1];
				h[j - 1] = tmp;
				c = j - 1;
			}
		}
	}while(c < 10);

	for(int i = 0; i < 3; i++)
		cout << h[i] << endl;

	return 0;
}