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

int main() {
	vector<int>a(10);
	for (int b = 0; b < 10; b++)cin >> a[b];
	sort(a.begin(), a.end());
	printf("%d\n%d\n%d\n", a[9], a[8], a[7]);
}