import java.util.Scanner;


public class Main {
	public static void main(String[] args) {
		Scanner input = new Scanner(System.in);
		
		int one = 0;
		int two = 0;
		int three = 0;
		
		
		
		for(int i = 0; i < 10; i++) {
			int x = input.nextInt();
			//System.out.println("x = " + x);
			if (x > one) {
				three = two;
				two = one;
				one = x;
			}
			else if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			}
		}
		
		System.out.println(one);
		System.out.println(two);
		System.out.println(three);
	}

} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner input = new Scanner(System.in);
		
		int one = 0;
		int two = 0;
		int three = 0;
		
		
		
		for(int i = 0; i < 10; i++) {
			int x = input.nextInt();
			//System.out.println("x = " + x);
			if (x > one) {
				three = two;
				two = one;
				one = x;
			}
			else if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			}
		}
		
		System.out.println(one);
		System.out.println(two);
		System.out.println(three);
	}

} Main public static void main(String[] args) {
		Scanner input = new Scanner(System.in);
		
		int one = 0;
		int two = 0;
		int three = 0;
		
		
		
		for(int i = 0; i < 10; i++) {
			int x = input.nextInt();
			//System.out.println("x = " + x);
			if (x > one) {
				three = two;
				two = one;
				one = x;
			}
			else if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			}
		}
		
		System.out.println(one);
		System.out.println(two);
		System.out.println(three);
	} main {
		Scanner input = new Scanner(System.in);
		
		int one = 0;
		int two = 0;
		int three = 0;
		
		
		
		for(int i = 0; i < 10; i++) {
			int x = input.nextInt();
			//System.out.println("x = " + x);
			if (x > one) {
				three = two;
				two = one;
				one = x;
			}
			else if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			}
		}
		
		System.out.println(one);
		System.out.println(two);
		System.out.println(three);
	} Scanner input = new Scanner(System.in); input new Scanner(System.in) int one = 0; one 0 int two = 0; two 0 int three = 0; three 0 for(int i = 0; i < 10; i++) {
			int x = input.nextInt();
			//System.out.println("x = " + x);
			if (x > one) {
				three = two;
				two = one;
				one = x;
			}
			else if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			}
		} int i = 0; int i = 0; i 0 i < 10 i 10 i++ i++ i {
			int x = input.nextInt();
			//System.out.println("x = " + x);
			if (x > one) {
				three = two;
				two = one;
				one = x;
			}
			else if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			}
		} {
			int x = input.nextInt();
			//System.out.println("x = " + x);
			if (x > one) {
				three = two;
				two = one;
				one = x;
			}
			else if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			}
		} int x = input.nextInt(); x input.nextInt() input.nextInt input if (x > one) {
				three = two;
				two = one;
				one = x;
			}
			else if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			} x > one x one {
				three = two;
				two = one;
				one = x;
			} three = two three two two = one two one one = x one x if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			} x > two x two {
				three = two;
				two = x;
			} three = two three two two = x two x if(x > three) {
				three = x;
			} x > three x three {
				three = x;
			} three = x three x System.out.println(one) System.out.println System.out System System.out one System.out.println(two) System.out.println System.out System System.out two System.out.println(three) System.out.println System.out System System.out three String[] args args public class Main {
	public static void main(String[] args) {
		Scanner input = new Scanner(System.in);
		
		int one = 0;
		int two = 0;
		int three = 0;
		
		
		
		for(int i = 0; i < 10; i++) {
			int x = input.nextInt();
			//System.out.println("x = " + x);
			if (x > one) {
				three = two;
				two = one;
				one = x;
			}
			else if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			}
		}
		
		System.out.println(one);
		System.out.println(two);
		System.out.println(three);
	}

} public class Main {
	public static void main(String[] args) {
		Scanner input = new Scanner(System.in);
		
		int one = 0;
		int two = 0;
		int three = 0;
		
		
		
		for(int i = 0; i < 10; i++) {
			int x = input.nextInt();
			//System.out.println("x = " + x);
			if (x > one) {
				three = two;
				two = one;
				one = x;
			}
			else if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			}
		}
		
		System.out.println(one);
		System.out.println(two);
		System.out.println(three);
	}

} Main
import java.util.Scanner;


public class Main {
	public static void main(String[] args) {
		Scanner input = new Scanner(System.in);
		
		int one = 0;
		int two = 0;
		int three = 0;
		
		
		
		for(int i = 0; i < 10; i++) {
			int x = input.nextInt();
			//System.out.println("x = " + x);
			if (x > one) {
				three = two;
				two = one;
				one = x;
			}
			else if (x > two) {
				three = two;
				two = x;
			}
			else if(x > three) {
				three = x;
			}
		}
		
		System.out.println(one);
		System.out.println(two);
		System.out.println(three);
	}

}