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

class Main {
	public static void main(String[] a) throws IOException {
		InputStreamReader is = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(is);
        int i = 0;
        int one=0;
        int two=0;
        int three=0;

        while(i<10){
        	int num=Integer.parseInt(br.readLine());
        	if(one<=num){
        		three=two;
        		two=one;
        		one=num;
        	}else if(two <= num){
        		three = two;
        		two=num;
        	}else if(three <=num){
        		three=num;
        	}
        	i++;
        }
        System.out.println(one);
        System.out.println(two);
        System.out.println(three);
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io class Main {
	public static void main(String[] a) throws IOException {
		InputStreamReader is = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(is);
        int i = 0;
        int one=0;
        int two=0;
        int three=0;

        while(i<10){
        	int num=Integer.parseInt(br.readLine());
        	if(one<=num){
        		three=two;
        		two=one;
        		one=num;
        	}else if(two <= num){
        		three = two;
        		two=num;
        	}else if(three <=num){
        		three=num;
        	}
        	i++;
        }
        System.out.println(one);
        System.out.println(two);
        System.out.println(three);
	}
} Main public static void main(String[] a) throws IOException {
		InputStreamReader is = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(is);
        int i = 0;
        int one=0;
        int two=0;
        int three=0;

        while(i<10){
        	int num=Integer.parseInt(br.readLine());
        	if(one<=num){
        		three=two;
        		two=one;
        		one=num;
        	}else if(two <= num){
        		three = two;
        		two=num;
        	}else if(three <=num){
        		three=num;
        	}
        	i++;
        }
        System.out.println(one);
        System.out.println(two);
        System.out.println(three);
	} main {
		InputStreamReader is = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(is);
        int i = 0;
        int one=0;
        int two=0;
        int three=0;

        while(i<10){
        	int num=Integer.parseInt(br.readLine());
        	if(one<=num){
        		three=two;
        		two=one;
        		one=num;
        	}else if(two <= num){
        		three = two;
        		two=num;
        	}else if(three <=num){
        		three=num;
        	}
        	i++;
        }
        System.out.println(one);
        System.out.println(two);
        System.out.println(three);
	} InputStreamReader is = new InputStreamReader(System.in); is new InputStreamReader(System.in) BufferedReader br = new BufferedReader(is); br new BufferedReader(is) int i = 0; i 0 int one=0; one 0 int two=0; two 0 int three=0; three 0 while(i<10){
        	int num=Integer.parseInt(br.readLine());
        	if(one<=num){
        		three=two;
        		two=one;
        		one=num;
        	}else if(two <= num){
        		three = two;
        		two=num;
        	}else if(three <=num){
        		three=num;
        	}
        	i++;
        } i<10 i 10 {
        	int num=Integer.parseInt(br.readLine());
        	if(one<=num){
        		three=two;
        		two=one;
        		one=num;
        	}else if(two <= num){
        		three = two;
        		two=num;
        	}else if(three <=num){
        		three=num;
        	}
        	i++;
        } int num=Integer.parseInt(br.readLine()); num Integer.parseInt(br.readLine()) Integer.parseInt Integer br.readLine() br.readLine br if(one<=num){
        		three=two;
        		two=one;
        		one=num;
        	}else if(two <= num){
        		three = two;
        		two=num;
        	}else if(three <=num){
        		three=num;
        	} one<=num one num {
        		three=two;
        		two=one;
        		one=num;
        	} three=two three two two=one two one one=num one num if(two <= num){
        		three = two;
        		two=num;
        	}else if(three <=num){
        		three=num;
        	} two <= num two num {
        		three = two;
        		two=num;
        	} three = two three two two=num two num if(three <=num){
        		three=num;
        	} three <=num three num {
        		three=num;
        	} three=num three num i++ i System.out.println(one) System.out.println System.out System System.out one System.out.println(two) System.out.println System.out System System.out two System.out.println(three) System.out.println System.out System System.out three String[] a a
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

class Main {
	public static void main(String[] a) throws IOException {
		InputStreamReader is = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(is);
        int i = 0;
        int one=0;
        int two=0;
        int three=0;

        while(i<10){
        	int num=Integer.parseInt(br.readLine());
        	if(one<=num){
        		three=two;
        		two=one;
        		one=num;
        	}else if(two <= num){
        		three = two;
        		two=num;
        	}else if(three <=num){
        		three=num;
        	}
        	i++;
        }
        System.out.println(one);
        System.out.println(two);
        System.out.println(three);
	}
}