borkins

04a. Greater Number

Mar 23rd, 2017
129
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.43 KB | None | 0 0
  1. /*
  2.  * Simple Conditions
  3.  */
  4. import java.util.Scanner;
  5.  
  6. public class _04a_GreaterNumber
  7. {
  8.     public static void main(String[] args)
  9.     {
  10.         Scanner scan = new Scanner(System.in);
  11.  
  12.         int a = Integer.parseInt(scan.nextLine());
  13.         int b = Integer.parseInt(scan.nextLine());
  14.  
  15.         if (a >= b) {
  16.             System.out.println(a);
  17.         }
  18.         else {
  19.             System.out.println(b);
  20.         }
  21.     }
  22. }
Advertisement
Add Comment
Please, Sign In to add comment