import java.util.*;
public class Main {
    public static void main(String[] args) {
        int first = 0;
        int second = 0;
        int third = 0;
        Scanner in = new Scanner(System.in);
        for (int i = 0; i < 10; i++) {
            int h = in.nextInt();
            if (h > first) {
                third = second;
                second = first;
                first = h;
            } else if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            }
        }
        System.out.println(first);
        System.out.println(second);
        System.out.println(third);
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args) {
        int first = 0;
        int second = 0;
        int third = 0;
        Scanner in = new Scanner(System.in);
        for (int i = 0; i < 10; i++) {
            int h = in.nextInt();
            if (h > first) {
                third = second;
                second = first;
                first = h;
            } else if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            }
        }
        System.out.println(first);
        System.out.println(second);
        System.out.println(third);
    }
} Main public static void main(String[] args) {
        int first = 0;
        int second = 0;
        int third = 0;
        Scanner in = new Scanner(System.in);
        for (int i = 0; i < 10; i++) {
            int h = in.nextInt();
            if (h > first) {
                third = second;
                second = first;
                first = h;
            } else if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            }
        }
        System.out.println(first);
        System.out.println(second);
        System.out.println(third);
    } main {
        int first = 0;
        int second = 0;
        int third = 0;
        Scanner in = new Scanner(System.in);
        for (int i = 0; i < 10; i++) {
            int h = in.nextInt();
            if (h > first) {
                third = second;
                second = first;
                first = h;
            } else if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            }
        }
        System.out.println(first);
        System.out.println(second);
        System.out.println(third);
    } int first = 0; first 0 int second = 0; second 0 int third = 0; third 0 Scanner in = new Scanner(System.in); in new Scanner(System.in) for (int i = 0; i < 10; i++) {
            int h = in.nextInt();
            if (h > first) {
                third = second;
                second = first;
                first = h;
            } else if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            }
        } int i = 0; int i = 0; i 0 i < 10 i 10 i++ i++ i {
            int h = in.nextInt();
            if (h > first) {
                third = second;
                second = first;
                first = h;
            } else if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            }
        } {
            int h = in.nextInt();
            if (h > first) {
                third = second;
                second = first;
                first = h;
            } else if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            }
        } int h = in.nextInt(); h in.nextInt() in.nextInt in if (h > first) {
                third = second;
                second = first;
                first = h;
            } else if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            } h > first h first {
                third = second;
                second = first;
                first = h;
            } third = second third second second = first second first first = h first h if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            } h > second h second {
                third = second;
                second = h;
            } third = second third second second = h second h if (h > third) {
                third = h;
            } h > third h third {
                third = h;
            } third = h third h System.out.println(first) System.out.println System.out System System.out first System.out.println(second) System.out.println System.out System System.out second System.out.println(third) System.out.println System.out System System.out third String[] args args public class Main {
    public static void main(String[] args) {
        int first = 0;
        int second = 0;
        int third = 0;
        Scanner in = new Scanner(System.in);
        for (int i = 0; i < 10; i++) {
            int h = in.nextInt();
            if (h > first) {
                third = second;
                second = first;
                first = h;
            } else if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            }
        }
        System.out.println(first);
        System.out.println(second);
        System.out.println(third);
    }
} public class Main {
    public static void main(String[] args) {
        int first = 0;
        int second = 0;
        int third = 0;
        Scanner in = new Scanner(System.in);
        for (int i = 0; i < 10; i++) {
            int h = in.nextInt();
            if (h > first) {
                third = second;
                second = first;
                first = h;
            } else if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            }
        }
        System.out.println(first);
        System.out.println(second);
        System.out.println(third);
    }
} Main
import java.util.*;
public class Main {
    public static void main(String[] args) {
        int first = 0;
        int second = 0;
        int third = 0;
        Scanner in = new Scanner(System.in);
        for (int i = 0; i < 10; i++) {
            int h = in.nextInt();
            if (h > first) {
                third = second;
                second = first;
                first = h;
            } else if (h > second) {
                third = second;
                second = h;
            } else if (h > third) {
                third = h;
            }
        }
        System.out.println(first);
        System.out.println(second);
        System.out.println(third);
    }
}