#include<iostream>
using namespace std;
int main() {
	int i, j, max;
	int v[10];
	for (i = 0; i < 10; i++) {
		cin >> v[i];
	}
	for (i = 0; i < 3; i++) {
		max = v[i];
		for (j = i; j < 10; j++) {
			if (max < v[j]) {
				max = v[j];
				v[j] = v[i];
				v[i] = max;
			}
		}

	}

	cout << v[0] <<"\n";
	cout << v[1] << "\n";
	cout << v[2] << "\n";
}

