import java.io.BufferedReader;
import java.io.InputStreamReader;


public class Main {
	
	public static void main(String input[]){
		int a = 0, b = 0, c=0;
		BufferedReader buffRead = new BufferedReader(new InputStreamReader(System.in));
		String fileline;
		try{
			while ((fileline = buffRead.readLine()) != null){
				int height = Integer.parseInt(fileline);
				if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				}
			}
		} catch (Exception e){
			System.out.println("Failure");
		}
		System.out.println(a);
		System.out.println(b);
		System.out.println(c);
	}	
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
	
	public static void main(String input[]){
		int a = 0, b = 0, c=0;
		BufferedReader buffRead = new BufferedReader(new InputStreamReader(System.in));
		String fileline;
		try{
			while ((fileline = buffRead.readLine()) != null){
				int height = Integer.parseInt(fileline);
				if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				}
			}
		} catch (Exception e){
			System.out.println("Failure");
		}
		System.out.println(a);
		System.out.println(b);
		System.out.println(c);
	}	
} Main public static void main(String input[]){
		int a = 0, b = 0, c=0;
		BufferedReader buffRead = new BufferedReader(new InputStreamReader(System.in));
		String fileline;
		try{
			while ((fileline = buffRead.readLine()) != null){
				int height = Integer.parseInt(fileline);
				if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				}
			}
		} catch (Exception e){
			System.out.println("Failure");
		}
		System.out.println(a);
		System.out.println(b);
		System.out.println(c);
	} main {
		int a = 0, b = 0, c=0;
		BufferedReader buffRead = new BufferedReader(new InputStreamReader(System.in));
		String fileline;
		try{
			while ((fileline = buffRead.readLine()) != null){
				int height = Integer.parseInt(fileline);
				if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				}
			}
		} catch (Exception e){
			System.out.println("Failure");
		}
		System.out.println(a);
		System.out.println(b);
		System.out.println(c);
	} int a = 0 a 0 b = 0 b 0 c=0; c 0 BufferedReader buffRead = new BufferedReader(new InputStreamReader(System.in)); buffRead new BufferedReader(new InputStreamReader(System.in)) String fileline; fileline try{
			while ((fileline = buffRead.readLine()) != null){
				int height = Integer.parseInt(fileline);
				if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				}
			}
		} catch (Exception e){
			System.out.println("Failure");
		} catch (Exception e){
			System.out.println("Failure");
		} Exception e {
			System.out.println("Failure");
		} System.out.println("Failure") System.out.println System.out System System.out "Failure" {
			while ((fileline = buffRead.readLine()) != null){
				int height = Integer.parseInt(fileline);
				if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				}
			}
		} while ((fileline = buffRead.readLine()) != null){
				int height = Integer.parseInt(fileline);
				if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				}
			} (fileline = buffRead.readLine()) != null (fileline = buffRead.readLine()) fileline buffRead.readLine() buffRead.readLine buffRead null {
				int height = Integer.parseInt(fileline);
				if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				}
			} int height = Integer.parseInt(fileline); height Integer.parseInt(fileline) Integer.parseInt Integer fileline if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				} height > a height a {
					c = b;
					b = a;
					a = height;		
				} c = b c b b = a b a a = height a height if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				} height > b height b {
					c = b;
					b = height;
				} c = b c b b = height b height if (height > c){
					c = height;
				}else{
					
				} height > c height c {
					c = height;
				} c = height c height {
					
				} System.out.println(a) System.out.println System.out System System.out a System.out.println(b) System.out.println System.out System System.out b System.out.println(c) System.out.println System.out System System.out c String input[] input public class Main {
	
	public static void main(String input[]){
		int a = 0, b = 0, c=0;
		BufferedReader buffRead = new BufferedReader(new InputStreamReader(System.in));
		String fileline;
		try{
			while ((fileline = buffRead.readLine()) != null){
				int height = Integer.parseInt(fileline);
				if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				}
			}
		} catch (Exception e){
			System.out.println("Failure");
		}
		System.out.println(a);
		System.out.println(b);
		System.out.println(c);
	}	
} public class Main {
	
	public static void main(String input[]){
		int a = 0, b = 0, c=0;
		BufferedReader buffRead = new BufferedReader(new InputStreamReader(System.in));
		String fileline;
		try{
			while ((fileline = buffRead.readLine()) != null){
				int height = Integer.parseInt(fileline);
				if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				}
			}
		} catch (Exception e){
			System.out.println("Failure");
		}
		System.out.println(a);
		System.out.println(b);
		System.out.println(c);
	}	
} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;


public class Main {
	
	public static void main(String input[]){
		int a = 0, b = 0, c=0;
		BufferedReader buffRead = new BufferedReader(new InputStreamReader(System.in));
		String fileline;
		try{
			while ((fileline = buffRead.readLine()) != null){
				int height = Integer.parseInt(fileline);
				if (height > a){
					c = b;
					b = a;
					a = height;		
				}else if (height > b){
					c = b;
					b = height;
				}else if (height > c){
					c = height;
				}else{
					
				}
			}
		} catch (Exception e){
			System.out.println("Failure");
		}
		System.out.println(a);
		System.out.println(b);
		System.out.println(c);
	}	
}