import java.util.*;
import java.io.*;

public class Main {
    public static void main(String[] args) throws IOException {
        Scanner sc=new Scanner(System.in);
        int max1=0,max2=0,max3=0;
        for (int i=1;i<=10;i++){
            int h=sc.nextInt();
            if (h>max1){
                max3=max2;
                max2=max1;
                max1=h;
            }
            else if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h;
        }
        System.out.println(max1);
        System.out.println(max2);
        System.out.println(max3);
    }
} import java.util.*; util.* java import java.io.*; io.* java public class Main {
    public static void main(String[] args) throws IOException {
        Scanner sc=new Scanner(System.in);
        int max1=0,max2=0,max3=0;
        for (int i=1;i<=10;i++){
            int h=sc.nextInt();
            if (h>max1){
                max3=max2;
                max2=max1;
                max1=h;
            }
            else if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h;
        }
        System.out.println(max1);
        System.out.println(max2);
        System.out.println(max3);
    }
} Main public static void main(String[] args) throws IOException {
        Scanner sc=new Scanner(System.in);
        int max1=0,max2=0,max3=0;
        for (int i=1;i<=10;i++){
            int h=sc.nextInt();
            if (h>max1){
                max3=max2;
                max2=max1;
                max1=h;
            }
            else if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h;
        }
        System.out.println(max1);
        System.out.println(max2);
        System.out.println(max3);
    } main {
        Scanner sc=new Scanner(System.in);
        int max1=0,max2=0,max3=0;
        for (int i=1;i<=10;i++){
            int h=sc.nextInt();
            if (h>max1){
                max3=max2;
                max2=max1;
                max1=h;
            }
            else if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h;
        }
        System.out.println(max1);
        System.out.println(max2);
        System.out.println(max3);
    } Scanner sc=new Scanner(System.in); sc new Scanner(System.in) int max1=0 max1 0 max2=0 max2 0 max3=0; max3 0 for (int i=1;i<=10;i++){
            int h=sc.nextInt();
            if (h>max1){
                max3=max2;
                max2=max1;
                max1=h;
            }
            else if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h;
        } int i=1; int i=1; i 1 i<=10 i 10 i++ i++ i {
            int h=sc.nextInt();
            if (h>max1){
                max3=max2;
                max2=max1;
                max1=h;
            }
            else if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h;
        } {
            int h=sc.nextInt();
            if (h>max1){
                max3=max2;
                max2=max1;
                max1=h;
            }
            else if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h;
        } int h=sc.nextInt(); h sc.nextInt() sc.nextInt sc if (h>max1){
                max3=max2;
                max2=max1;
                max1=h;
            }
            else if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h; h>max1 h max1 {
                max3=max2;
                max2=max1;
                max1=h;
            } max3=max2 max3 max2 max2=max1 max2 max1 max1=h max1 h if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h; h>max2 h max2 {
                max3=max2;
                max2=h;
            } max3=max2 max3 max2 max2=h max2 h if (h>max3)
                max3=h; h>max3 h max3 max3=h max3 h System.out.println(max1) System.out.println System.out System System.out max1 System.out.println(max2) System.out.println System.out System System.out max2 System.out.println(max3) System.out.println System.out System System.out max3 String[] args args public class Main {
    public static void main(String[] args) throws IOException {
        Scanner sc=new Scanner(System.in);
        int max1=0,max2=0,max3=0;
        for (int i=1;i<=10;i++){
            int h=sc.nextInt();
            if (h>max1){
                max3=max2;
                max2=max1;
                max1=h;
            }
            else if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h;
        }
        System.out.println(max1);
        System.out.println(max2);
        System.out.println(max3);
    }
} public class Main {
    public static void main(String[] args) throws IOException {
        Scanner sc=new Scanner(System.in);
        int max1=0,max2=0,max3=0;
        for (int i=1;i<=10;i++){
            int h=sc.nextInt();
            if (h>max1){
                max3=max2;
                max2=max1;
                max1=h;
            }
            else if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h;
        }
        System.out.println(max1);
        System.out.println(max2);
        System.out.println(max3);
    }
} Main
import java.util.*;
import java.io.*;

public class Main {
    public static void main(String[] args) throws IOException {
        Scanner sc=new Scanner(System.in);
        int max1=0,max2=0,max3=0;
        for (int i=1;i<=10;i++){
            int h=sc.nextInt();
            if (h>max1){
                max3=max2;
                max2=max1;
                max1=h;
            }
            else if (h>max2){
                max3=max2;
                max2=h;
            }
            else if (h>max3)
                max3=h;
        }
        System.out.println(max1);
        System.out.println(max2);
        System.out.println(max3);
    }
}