#include <iostream>
#include <algorithm>
#include <functional>

int main(){
	int a[10];

	for (int i = 0; i != 10; i++)
		std::cin >> a[i];
	std::sort(a, a + 10, std::greater<int>());
	for (int j = 0; j != 3; j++)
		std::cout << a[j] << std::endl;
	return 0;
}