#import int i=10,xs[10]; main(){for(;i--;)scanf("%d",&xs[i]);std::sort(xs,xs+10);printf("%d",xs[7]);}