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

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

	for (i = 0; i < 9; i++){
		for (j = i+1; j < 10; j++){
			if (mt[j] >= mt[i]){
				buf = mt[i];
				mt[i] = mt[j];
				mt[j] = buf;
			}

		}	
	}

	for (i = 0; i < 3; i++){
		printf("%d\n", mt[i]);
	}
	return 0;
}