import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {

	public static void main(String[] args) throws NumberFormatException, IOException {
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		int[] rank3 = {0,0,0};
		int mountain;
		for(int i=0; i<10; i++){
			mountain = Integer.parseInt(r.readLine());
			if(rank3[0] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			}else if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			}
		}
		for(int i=0; i<3; i++){
			System.out.println(rank3[i]);
		}
	}

} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {

	public static void main(String[] args) throws NumberFormatException, IOException {
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		int[] rank3 = {0,0,0};
		int mountain;
		for(int i=0; i<10; i++){
			mountain = Integer.parseInt(r.readLine());
			if(rank3[0] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			}else if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			}
		}
		for(int i=0; i<3; i++){
			System.out.println(rank3[i]);
		}
	}

} Main public static void main(String[] args) throws NumberFormatException, IOException {
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		int[] rank3 = {0,0,0};
		int mountain;
		for(int i=0; i<10; i++){
			mountain = Integer.parseInt(r.readLine());
			if(rank3[0] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			}else if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			}
		}
		for(int i=0; i<3; i++){
			System.out.println(rank3[i]);
		}
	} main {
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		int[] rank3 = {0,0,0};
		int mountain;
		for(int i=0; i<10; i++){
			mountain = Integer.parseInt(r.readLine());
			if(rank3[0] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			}else if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			}
		}
		for(int i=0; i<3; i++){
			System.out.println(rank3[i]);
		}
	} BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1); r new BufferedReader(new InputStreamReader(System.in),1) int[] rank3 = {0,0,0}; rank3 {0,0,0} 0 0 0 int mountain; mountain for(int i=0; i<10; i++){
			mountain = Integer.parseInt(r.readLine());
			if(rank3[0] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			}else if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			}
		} int i=0; int i=0; i 0 i<10 i 10 i++ i++ i {
			mountain = Integer.parseInt(r.readLine());
			if(rank3[0] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			}else if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			}
		} {
			mountain = Integer.parseInt(r.readLine());
			if(rank3[0] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			}else if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			}
		} mountain = Integer.parseInt(r.readLine()) mountain Integer.parseInt(r.readLine()) Integer.parseInt Integer r.readLine() r.readLine r if(rank3[0] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			}else if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			} rank3[0] < mountain rank3[0] rank3 0 mountain {
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			} rank3[2] = rank3[1] rank3[2] rank3 2 rank3[1] rank3 1 rank3[1] = rank3[0] rank3[1] rank3 1 rank3[0] rank3 0 rank3[0] = mountain rank3[0] rank3 0 mountain if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			} rank3[1] < mountain rank3[1] rank3 1 mountain {
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			} rank3[2] = rank3[1] rank3[2] rank3 2 rank3[1] rank3 1 rank3[1] = mountain rank3[1] rank3 1 mountain if(rank3[2] < mountain){
				rank3[2] = mountain;
			} rank3[2] < mountain rank3[2] rank3 2 mountain {
				rank3[2] = mountain;
			} rank3[2] = mountain rank3[2] rank3 2 mountain for(int i=0; i<3; i++){
			System.out.println(rank3[i]);
		} int i=0; int i=0; i 0 i<3 i 3 i++ i++ i {
			System.out.println(rank3[i]);
		} {
			System.out.println(rank3[i]);
		} System.out.println(rank3[i]) System.out.println System.out System System.out rank3[i] rank3 i String[] args args public class Main {

	public static void main(String[] args) throws NumberFormatException, IOException {
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		int[] rank3 = {0,0,0};
		int mountain;
		for(int i=0; i<10; i++){
			mountain = Integer.parseInt(r.readLine());
			if(rank3[0] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			}else if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			}
		}
		for(int i=0; i<3; i++){
			System.out.println(rank3[i]);
		}
	}

} public class Main {

	public static void main(String[] args) throws NumberFormatException, IOException {
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		int[] rank3 = {0,0,0};
		int mountain;
		for(int i=0; i<10; i++){
			mountain = Integer.parseInt(r.readLine());
			if(rank3[0] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			}else if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			}
		}
		for(int i=0; i<3; i++){
			System.out.println(rank3[i]);
		}
	}

} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {

	public static void main(String[] args) throws NumberFormatException, IOException {
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		int[] rank3 = {0,0,0};
		int mountain;
		for(int i=0; i<10; i++){
			mountain = Integer.parseInt(r.readLine());
			if(rank3[0] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = rank3[0];
				rank3[0] = mountain;
			}else if(rank3[1] < mountain){
				rank3[2] = rank3[1];
				rank3[1] = mountain;
			}else if(rank3[2] < mountain){
				rank3[2] = mountain;
			}
		}
		for(int i=0; i<3; i++){
			System.out.println(rank3[i]);
		}
	}

}