#include<stdio.h>

int main(void){
    int ex,i,j,high[10];


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

    for(i = 0;i < 10;i++){
        for(j = i + 1;j < 10;j++){
            if(high[i] > high[j]){
                ex = high[i];
                high[i] = high[j];
                high[j] = ex;
            }
        }
    }

    printf("%d\n%d\n%d\n",high[9],high[8],high[7]);
    return 0;
}