#include <array>
#include <vector>
#include <deque>
#include <queue>
#include <set>
#include <unordered_set>
#include <map>
#include <unordered_map>
#include <string>
#include <algorithm>
#include <numeric>
#include <functional>
#include <iterator>
#include <tuple>
#include <utility>
#include <limits>
#include <iostream>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <cmath>
#include <cstdint>
#include <cassert>

using namespace std;

#define FOR(i, start, end) for(int i = (start); i < (end); ++i)
#define REP(i, n) FOR(i, 0, n)



int main()
{
    array<int, 10> a;
    REP(i, 10) {
        cin >> a[i];
    }

    partial_sort(begin(a), begin(a)+3, end(a), greater<int>());

    REP(i, 3) {
        cout << a[i] << "\n";
    }

    return 0;
}