#include<iostream>
#include<vector>
#include<algorithm>

int main(){
	std::vector<int> mountain(10, 0);
	
	for(int i = 0; i < 10; ++i){
		std::cin >> mountain[i];
	}
	
	std::sort(mountain.begin(), mountain.end(), std::greater<int>());
	for(int i = 0; i < 3; ++i){
		std::cout << mountain[i] << std::endl;
	}
	
	return 0;
}