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

using namespace std;

int main(void){
	int hill;

	deque<int> nums;

	for(int i=0; i<10; i++){
		cin >> hill;
		nums.push_back(hill);
	}

	sort(nums.begin(), nums.end(),greater<int>());

	for(int j=0; j<3; j++){
		cout << nums[j] << endl;
	}

	return 0;
}