#include <iostream>
#include <algorithm>
int main() {
  int data[10];
  for (int i = 0; i < 10; i++) {
    std::cin >> data[i];
  }
  std::sort(data,data+10,std::greater<int>());
  for (int i = 0; i < 3; i++) {
    std::cout << data[i] << std::endl;
  }
}