import java.util.*;

public class Main {	
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        ArrayList<Integer> mountain = new ArrayList<Integer>();
        
        for(int i=0;i<10;i++){
        mountain.add(Integer.parseInt(sc.nextLine()));
        }
        
        for(int i=0;i<3;i++){      	
        	int max = mountain.get(0);
        	int save=0;
        	for(int j=0;j<mountain.size();j++){
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	}
        	System.out.println(mountain.get(save));
        	mountain.remove(save);        	
        }
    }
} import java.util.*; util.* java public class Main {	
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        ArrayList<Integer> mountain = new ArrayList<Integer>();
        
        for(int i=0;i<10;i++){
        mountain.add(Integer.parseInt(sc.nextLine()));
        }
        
        for(int i=0;i<3;i++){      	
        	int max = mountain.get(0);
        	int save=0;
        	for(int j=0;j<mountain.size();j++){
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	}
        	System.out.println(mountain.get(save));
        	mountain.remove(save);        	
        }
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        ArrayList<Integer> mountain = new ArrayList<Integer>();
        
        for(int i=0;i<10;i++){
        mountain.add(Integer.parseInt(sc.nextLine()));
        }
        
        for(int i=0;i<3;i++){      	
        	int max = mountain.get(0);
        	int save=0;
        	for(int j=0;j<mountain.size();j++){
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	}
        	System.out.println(mountain.get(save));
        	mountain.remove(save);        	
        }
    } main {
        Scanner sc = new Scanner(System.in);
        
        ArrayList<Integer> mountain = new ArrayList<Integer>();
        
        for(int i=0;i<10;i++){
        mountain.add(Integer.parseInt(sc.nextLine()));
        }
        
        for(int i=0;i<3;i++){      	
        	int max = mountain.get(0);
        	int save=0;
        	for(int j=0;j<mountain.size();j++){
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	}
        	System.out.println(mountain.get(save));
        	mountain.remove(save);        	
        }
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) ArrayList<Integer> mountain = new ArrayList<Integer>(); mountain new ArrayList<Integer>() for(int i=0;i<10;i++){
        mountain.add(Integer.parseInt(sc.nextLine()));
        } int i=0; int i=0; i 0 i<10 i 10 i++ i++ i {
        mountain.add(Integer.parseInt(sc.nextLine()));
        } {
        mountain.add(Integer.parseInt(sc.nextLine()));
        } mountain.add(Integer.parseInt(sc.nextLine())) mountain.add mountain Integer.parseInt(sc.nextLine()) Integer.parseInt Integer sc.nextLine() sc.nextLine sc for(int i=0;i<3;i++){      	
        	int max = mountain.get(0);
        	int save=0;
        	for(int j=0;j<mountain.size();j++){
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	}
        	System.out.println(mountain.get(save));
        	mountain.remove(save);        	
        } int i=0; int i=0; i 0 i<3 i 3 i++ i++ i {      	
        	int max = mountain.get(0);
        	int save=0;
        	for(int j=0;j<mountain.size();j++){
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	}
        	System.out.println(mountain.get(save));
        	mountain.remove(save);        	
        } {      	
        	int max = mountain.get(0);
        	int save=0;
        	for(int j=0;j<mountain.size();j++){
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	}
        	System.out.println(mountain.get(save));
        	mountain.remove(save);        	
        } int max = mountain.get(0); max mountain.get(0) mountain.get mountain 0 int save=0; save 0 for(int j=0;j<mountain.size();j++){
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	} int j=0; int j=0; j 0 j<mountain.size() j mountain.size() mountain.size mountain j++ j++ j {
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	} {
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	} if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} max<mountain.get(j) max mountain.get(j) mountain.get mountain j {
        			max=mountain.get(j);
        			save=j;
        		} max=mountain.get(j) max mountain.get(j) mountain.get mountain j save=j save j System.out.println(mountain.get(save)) System.out.println System.out System System.out mountain.get(save) mountain.get mountain save mountain.remove(save) mountain.remove mountain save String[] args args public class Main {	
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        ArrayList<Integer> mountain = new ArrayList<Integer>();
        
        for(int i=0;i<10;i++){
        mountain.add(Integer.parseInt(sc.nextLine()));
        }
        
        for(int i=0;i<3;i++){      	
        	int max = mountain.get(0);
        	int save=0;
        	for(int j=0;j<mountain.size();j++){
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	}
        	System.out.println(mountain.get(save));
        	mountain.remove(save);        	
        }
    }
} public class Main {	
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        ArrayList<Integer> mountain = new ArrayList<Integer>();
        
        for(int i=0;i<10;i++){
        mountain.add(Integer.parseInt(sc.nextLine()));
        }
        
        for(int i=0;i<3;i++){      	
        	int max = mountain.get(0);
        	int save=0;
        	for(int j=0;j<mountain.size();j++){
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	}
        	System.out.println(mountain.get(save));
        	mountain.remove(save);        	
        }
    }
} Main
import java.util.*;

public class Main {	
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        ArrayList<Integer> mountain = new ArrayList<Integer>();
        
        for(int i=0;i<10;i++){
        mountain.add(Integer.parseInt(sc.nextLine()));
        }
        
        for(int i=0;i<3;i++){      	
        	int max = mountain.get(0);
        	int save=0;
        	for(int j=0;j<mountain.size();j++){
        		if(max<mountain.get(j)){
        			max=mountain.get(j);
        			save=j;
        		} 		
        	}
        	System.out.println(mountain.get(save));
        	mountain.remove(save);        	
        }
    }
}