import java.util.*;

public class Main {

    public static void topThreeHills() {
        // Get 10 inputs for mountain heights
        Scanner scanner = new Scanner(System.in);
        int[] heights = new int[10];
        for (int i = 0; i < heights.length; i++) {
            heights[i] = scanner.nextInt();
        }

        // Find top three heights
        /*
        int[] threeHighest = Arrays.copyOfRange(heights, 0, 3);
        for (int i = 3; i < 10; i++) {
            if (heights[i] > threeHighest[0])
                threeHighest[0] = heights[i];
            else if (heights[i] > threeHighest[1])
                threeHighest[1] = heights[i];
            else if (heights[i] > threeHighest[2])
                threeHighest[2] = heights[i];
        }

        System.out.println(" ");
        System.out.println(threeHighest[0]);
        System.out.println(threeHighest[1]);
        System.out.println(threeHighest[2]);
        */

        Arrays.sort(heights);
        System.out.println(heights[9]);
        System.out.println(heights[8]);
        System.out.println(heights[7]);
    }

    public static void main (String args[]) {
        topThreeHills();
    }
} import java.util.*; util.* java public class Main {

    public static void topThreeHills() {
        // Get 10 inputs for mountain heights
        Scanner scanner = new Scanner(System.in);
        int[] heights = new int[10];
        for (int i = 0; i < heights.length; i++) {
            heights[i] = scanner.nextInt();
        }

        // Find top three heights
        /*
        int[] threeHighest = Arrays.copyOfRange(heights, 0, 3);
        for (int i = 3; i < 10; i++) {
            if (heights[i] > threeHighest[0])
                threeHighest[0] = heights[i];
            else if (heights[i] > threeHighest[1])
                threeHighest[1] = heights[i];
            else if (heights[i] > threeHighest[2])
                threeHighest[2] = heights[i];
        }

        System.out.println(" ");
        System.out.println(threeHighest[0]);
        System.out.println(threeHighest[1]);
        System.out.println(threeHighest[2]);
        */

        Arrays.sort(heights);
        System.out.println(heights[9]);
        System.out.println(heights[8]);
        System.out.println(heights[7]);
    }

    public static void main (String args[]) {
        topThreeHills();
    }
} Main public static void topThreeHills() {
        // Get 10 inputs for mountain heights
        Scanner scanner = new Scanner(System.in);
        int[] heights = new int[10];
        for (int i = 0; i < heights.length; i++) {
            heights[i] = scanner.nextInt();
        }

        // Find top three heights
        /*
        int[] threeHighest = Arrays.copyOfRange(heights, 0, 3);
        for (int i = 3; i < 10; i++) {
            if (heights[i] > threeHighest[0])
                threeHighest[0] = heights[i];
            else if (heights[i] > threeHighest[1])
                threeHighest[1] = heights[i];
            else if (heights[i] > threeHighest[2])
                threeHighest[2] = heights[i];
        }

        System.out.println(" ");
        System.out.println(threeHighest[0]);
        System.out.println(threeHighest[1]);
        System.out.println(threeHighest[2]);
        */

        Arrays.sort(heights);
        System.out.println(heights[9]);
        System.out.println(heights[8]);
        System.out.println(heights[7]);
    } topThreeHills {
        // Get 10 inputs for mountain heights
        Scanner scanner = new Scanner(System.in);
        int[] heights = new int[10];
        for (int i = 0; i < heights.length; i++) {
            heights[i] = scanner.nextInt();
        }

        // Find top three heights
        /*
        int[] threeHighest = Arrays.copyOfRange(heights, 0, 3);
        for (int i = 3; i < 10; i++) {
            if (heights[i] > threeHighest[0])
                threeHighest[0] = heights[i];
            else if (heights[i] > threeHighest[1])
                threeHighest[1] = heights[i];
            else if (heights[i] > threeHighest[2])
                threeHighest[2] = heights[i];
        }

        System.out.println(" ");
        System.out.println(threeHighest[0]);
        System.out.println(threeHighest[1]);
        System.out.println(threeHighest[2]);
        */

        Arrays.sort(heights);
        System.out.println(heights[9]);
        System.out.println(heights[8]);
        System.out.println(heights[7]);
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int[] heights = new int[10]; heights new int[10] 10 for (int i = 0; i < heights.length; i++) {
            heights[i] = scanner.nextInt();
        } int i = 0; int i = 0; i 0 i < heights.length i heights.length heights heights.length i++ i++ i {
            heights[i] = scanner.nextInt();
        } {
            heights[i] = scanner.nextInt();
        } heights[i] = scanner.nextInt() heights[i] heights i scanner.nextInt() scanner.nextInt scanner Arrays.sort(heights) Arrays.sort Arrays heights System.out.println(heights[9]) System.out.println System.out System System.out heights[9] heights 9 System.out.println(heights[8]) System.out.println System.out System System.out heights[8] heights 8 System.out.println(heights[7]) System.out.println System.out System System.out heights[7] heights 7 public static void main (String args[]) {
        topThreeHills();
    } main {
        topThreeHills();
    } topThreeHills() topThreeHills String args[] args public class Main {

    public static void topThreeHills() {
        // Get 10 inputs for mountain heights
        Scanner scanner = new Scanner(System.in);
        int[] heights = new int[10];
        for (int i = 0; i < heights.length; i++) {
            heights[i] = scanner.nextInt();
        }

        // Find top three heights
        /*
        int[] threeHighest = Arrays.copyOfRange(heights, 0, 3);
        for (int i = 3; i < 10; i++) {
            if (heights[i] > threeHighest[0])
                threeHighest[0] = heights[i];
            else if (heights[i] > threeHighest[1])
                threeHighest[1] = heights[i];
            else if (heights[i] > threeHighest[2])
                threeHighest[2] = heights[i];
        }

        System.out.println(" ");
        System.out.println(threeHighest[0]);
        System.out.println(threeHighest[1]);
        System.out.println(threeHighest[2]);
        */

        Arrays.sort(heights);
        System.out.println(heights[9]);
        System.out.println(heights[8]);
        System.out.println(heights[7]);
    }

    public static void main (String args[]) {
        topThreeHills();
    }
} public class Main {

    public static void topThreeHills() {
        // Get 10 inputs for mountain heights
        Scanner scanner = new Scanner(System.in);
        int[] heights = new int[10];
        for (int i = 0; i < heights.length; i++) {
            heights[i] = scanner.nextInt();
        }

        // Find top three heights
        /*
        int[] threeHighest = Arrays.copyOfRange(heights, 0, 3);
        for (int i = 3; i < 10; i++) {
            if (heights[i] > threeHighest[0])
                threeHighest[0] = heights[i];
            else if (heights[i] > threeHighest[1])
                threeHighest[1] = heights[i];
            else if (heights[i] > threeHighest[2])
                threeHighest[2] = heights[i];
        }

        System.out.println(" ");
        System.out.println(threeHighest[0]);
        System.out.println(threeHighest[1]);
        System.out.println(threeHighest[2]);
        */

        Arrays.sort(heights);
        System.out.println(heights[9]);
        System.out.println(heights[8]);
        System.out.println(heights[7]);
    }

    public static void main (String args[]) {
        topThreeHills();
    }
} Main
import java.util.*;

public class Main {

    public static void topThreeHills() {
        // Get 10 inputs for mountain heights
        Scanner scanner = new Scanner(System.in);
        int[] heights = new int[10];
        for (int i = 0; i < heights.length; i++) {
            heights[i] = scanner.nextInt();
        }

        // Find top three heights
        /*
        int[] threeHighest = Arrays.copyOfRange(heights, 0, 3);
        for (int i = 3; i < 10; i++) {
            if (heights[i] > threeHighest[0])
                threeHighest[0] = heights[i];
            else if (heights[i] > threeHighest[1])
                threeHighest[1] = heights[i];
            else if (heights[i] > threeHighest[2])
                threeHighest[2] = heights[i];
        }

        System.out.println(" ");
        System.out.println(threeHighest[0]);
        System.out.println(threeHighest[1]);
        System.out.println(threeHighest[2]);
        */

        Arrays.sort(heights);
        System.out.println(heights[9]);
        System.out.println(heights[8]);
        System.out.println(heights[7]);
    }

    public static void main (String args[]) {
        topThreeHills();
    }
}