/** || By The Name of Allah, Who Created Me. || **/

/**
	* Author   : Farid ul Islam Chy.
	* ID       : 1512020238.
	* Batch    : 38th.
	* Semester : 4C(E).
	* Team     : LU_AntiVirus.

	* Leading University, Sylhet.
**/

#include <map>
#include <set>
#include <stack>
#include <queue>
#include <math.h>
#include <cstdio>
#include <vector>
#include <cstring>
#include <utility>
#include <ctype.h>
#include <iomanip>
#include <iterator>
#include <iostream>
#include <algorithm>
#include <sstream>
#include <stdlib.h>
#include <fstream>

using namespace std;

#define ll    		    long long int
#define SS		    stringstream
#define pb    		    push_back
#define ull    		    unsigned long long int
#define MII        	    map <int,int>
#define MSI        	    map <string,int>
#define MIS        	    map <int,string>
#define MLI         	    map <long long int,int>
#define MIL        	    map <int,long long int>
#define MLL        	    map <ll,ll>
#define VS        	    vector <string>
#define VI        	    vector <ll>
#define VC        	    vector <char>
#define ForA(n)  	    for (int i=0; i<n; i++)
#define ForA2(n)  	    for (int j=0; j<n; j++)
#define ForA3(n)  	    for (int k=0; k<n; k++)
#define ForAS(n)  	    for (int i=n; i>0; i--)
#define ForN(n)  	    for (int i=1; i<=n; i++)
#define ForN2(n)  	    for (int j=1; j<=n; j++)
#define ForN3(n)  	    for (int k=1; k<=n; k++)
#define ForD(m,n)  	    for (int i=m; i<=n; i++)
#define ForD2(m,n)  	    for (int j=m; j<=n; j++)
#define ForD3(m,n) 	    for (int k=m; k<=n; k++)
#define SortA(n,x) 	    sort(n,n+x)
#define SortS(s)  	    sort(s.begin(), s.end())
#define SortRS(s)  	    sort(s.rbegin(), s.rend())
#define Search(s)           s.begin(), s.end()
#define SortSG(n)	    sort(n.begin(), n.end(), greater<int>())
#define Cin(a)		    cin>>a
#define GCin(a)		    getline(cin,a)
#define Cin2(a,b)	    cin>>a>>b
#define Cin3(a,b,c)	    cin>>a>>b>>c
#define Cin4(a,b,c,d)	    cin>>a>>b>>c>>d
#define PI 		    3.1415926535897932384626433832795l
#define Ignore		    cin.ignore()

int isprime(ll n){
     ll i;
     if(n==2) return 1;
     if(n%2==0) return 0;
     for(i=3;i<=sqrt(n);i+=2)
         if(n%i==0) return 0;
     return 1;
}

bool cmp(string i,string j){
    return i+j<j+i;
}

string ConvertItoS(ll n){
    SS a; a<<n;
    return a.str();
}

//ll ConvertStoI(string s){
//   return stoi(s);
//}

int main(){
    //freopen("in.txt","r",stdin)
    //freopen("out.txt","w",stdout)
    //cout<<fixed<<setprecision(2);
    ios_base::sync_with_stdio(0);
    cin.tie(0);
    cout.tie(0);

	VI(v);
	ll m;

	ForA(10){
	    Cin(m);
	    v.pb(m);
	}
	SortS(v);
	ll len=v.size();
	cout<<v[len-1]<<endl;
	cout<<v[len-2]<<endl;
	cout<<v[len-3]<<endl;
	
    return 0;
}