#include<iostream>
#include<string>
#include<vector>
#include<algorithm>
#include <functional>
using namespace std;

#define rep(p,q) for(int i = p; i < q;i++)

//1

int main(void) {
	vector<int> mountain = vector<int>();
	rep(0, 10) {
		int x;
		cin >> x;
		mountain.push_back(x);
	}
	sort(mountain.begin(), mountain.end(), greater<int>());
	rep(0, 3) {
		cout << mountain[i] << endl;
	}
}

