import std.stdio;
import std.array;
import std.algorithm;
import std.string;
import std.conv;

void main(){
    int[10] height;
    foreach(int i ; 0 .. 10){
        height[i] = to!int(readln().chomp());
    }
    height.sort;
    writef("%d\n%d\n%d\n", height[9], height[8], height[7]);
}