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

void main() {
    auto inputs = getStdin!(int[]).sort!("a > b")[0..3];
    foreach (n; inputs) n.writeln;
}

T getStdin(T)() {
    string[] cmd;
    string line;
    while ((line = chomp(stdin.readln())) != "") cmd ~= line;
    return to!(T)(cmd);
}