var lines=[];
var reader = require('readline').createInterface({
    input: process.stdin,
    output: process.stdout
});
reader.on('line', function (line) {
  lines.push(line);
});
reader.on('close', function () {
  //do something
  console.log(lines.sort(function(a,b){
	  return b - a;
  }).slice(0,3).join('\n'));
});