var fs = require("fs");
var input = fs.readFileSync('/dev/stdin').toString();
var mountains = input.split("\n").map(Number);
var mountains.sort(sortNumber);

function sortNumber(a,b) {
    return b - a;
}

for (i=0; i!=3; i++) {
    console.log(mountains[i]);
}