import java.util.*;
import java.io.*;
import static java.lang.Integer.parseInt;

public class Main {
    
    public static void main(String[] arg) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        ArrayList<Integer> al = new ArrayList<>();
        int i = 0,j=0;
        while(i<10){
            int x = parseInt(br.readLine());
            if(0<=x&&x<=10000){
            al.add(x);
            }
            i++;
        }
        Collections.sort(al,Comparator.reverseOrder());
        while(j<3){
            System.out.println(al.get(j));
            j++;
        }
    }
} import java.util.*; util.* java import java.io.*; io.* java import static java.lang.Integer.parseInt; import static java.lang.Integer.parseInt; import static java.lang.Integer.parseInt; public class Main {
    
    public static void main(String[] arg) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        ArrayList<Integer> al = new ArrayList<>();
        int i = 0,j=0;
        while(i<10){
            int x = parseInt(br.readLine());
            if(0<=x&&x<=10000){
            al.add(x);
            }
            i++;
        }
        Collections.sort(al,Comparator.reverseOrder());
        while(j<3){
            System.out.println(al.get(j));
            j++;
        }
    }
} Main public static void main(String[] arg) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        ArrayList<Integer> al = new ArrayList<>();
        int i = 0,j=0;
        while(i<10){
            int x = parseInt(br.readLine());
            if(0<=x&&x<=10000){
            al.add(x);
            }
            i++;
        }
        Collections.sort(al,Comparator.reverseOrder());
        while(j<3){
            System.out.println(al.get(j));
            j++;
        }
    } main {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        ArrayList<Integer> al = new ArrayList<>();
        int i = 0,j=0;
        while(i<10){
            int x = parseInt(br.readLine());
            if(0<=x&&x<=10000){
            al.add(x);
            }
            i++;
        }
        Collections.sort(al,Comparator.reverseOrder());
        while(j<3){
            System.out.println(al.get(j));
            j++;
        }
    } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) ArrayList<Integer> al = new ArrayList<>(); al new ArrayList<>() int i = 0 i 0 j=0; j 0 while(i<10){
            int x = parseInt(br.readLine());
            if(0<=x&&x<=10000){
            al.add(x);
            }
            i++;
        } i<10 i 10 {
            int x = parseInt(br.readLine());
            if(0<=x&&x<=10000){
            al.add(x);
            }
            i++;
        } int x = parseInt(br.readLine()); x parseInt(br.readLine()) parseInt br.readLine() br.readLine br if(0<=x&&x<=10000){
            al.add(x);
            } 0<=x&&x<=10000 0<=x 0 x x<=10000 x 10000 {
            al.add(x);
            } al.add(x) al.add al x i++ i Collections.sort(al,Comparator.reverseOrder()) Collections.sort Collections al Comparator.reverseOrder() Comparator.reverseOrder Comparator while(j<3){
            System.out.println(al.get(j));
            j++;
        } j<3 j 3 {
            System.out.println(al.get(j));
            j++;
        } System.out.println(al.get(j)) System.out.println System.out System System.out al.get(j) al.get al j j++ j String[] arg arg public class Main {
    
    public static void main(String[] arg) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        ArrayList<Integer> al = new ArrayList<>();
        int i = 0,j=0;
        while(i<10){
            int x = parseInt(br.readLine());
            if(0<=x&&x<=10000){
            al.add(x);
            }
            i++;
        }
        Collections.sort(al,Comparator.reverseOrder());
        while(j<3){
            System.out.println(al.get(j));
            j++;
        }
    }
} public class Main {
    
    public static void main(String[] arg) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        ArrayList<Integer> al = new ArrayList<>();
        int i = 0,j=0;
        while(i<10){
            int x = parseInt(br.readLine());
            if(0<=x&&x<=10000){
            al.add(x);
            }
            i++;
        }
        Collections.sort(al,Comparator.reverseOrder());
        while(j<3){
            System.out.println(al.get(j));
            j++;
        }
    }
} Main
import java.util.*;
import java.io.*;
import static java.lang.Integer.parseInt;

public class Main {
    
    public static void main(String[] arg) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        ArrayList<Integer> al = new ArrayList<>();
        int i = 0,j=0;
        while(i<10){
            int x = parseInt(br.readLine());
            if(0<=x&&x<=10000){
            al.add(x);
            }
            i++;
        }
        Collections.sort(al,Comparator.reverseOrder());
        while(j<3){
            System.out.println(al.get(j));
            j++;
        }
    }
}