#include <iostream>
using namespace std;
int M[10];

void bubbleSort(int M[], int N) {
	int flag = 1;
	while (flag) {
		flag = 0;
		for (int i = N - 1; i > 0; --i) {
			if (M[i - 1] > M[i]) {
				int t = M[i];
				M[i] = M[i - 1];
				M[i - 1] = t;
				flag = 1;
			}
		}
	}
}

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

	bubbleSort(M, 10);

	for (int i = 1; i < 4; ++i) {
		cout << M[10 - i] << " ";
	}
	cout << endl;
}
