#include <stdio.h>
int main(void)
{
	int i, j, hill[10], temp;

	for(i = 0; i < 10; i++)
		scanf("%d", &hill[i]);

	for (i = 0; i < 9; i++) {
		for (j = i; j < 10; j++) {
			if (hill[i] < hill[j]) {
				temp = hill[i];
				hill[i] = hill[j];
				hill[j] = temp;
			}
		}
	}

	for (i = 0; i < 3; i++)
		printf("%d\n", hill[i]);

	return 0;
}