Xadez

odd or even

Apr 14th, 2017
124
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.50 KB | None | 0 0
  1. import java.util.Scanner;
  2.  
  3. public class Learning {
  4.  
  5.     public static void main(String[] args) {
  6.         Scanner console = new Scanner(System.in);
  7.  
  8.         int firstNumber = Integer.parseInt(console.nextLine());
  9.         int secondNumber = Integer.parseInt(console.nextLine());
  10.  
  11.         if (firstNumber > secondNumber) {
  12.                 System.out.println("The greater number is first!");
  13.             } else {
  14.                 System.out.println("The greater number is second");
  15.         }
  16.     }
  17. }
Advertisement
Add Comment
Please, Sign In to add comment