jwrbg

MaxNumber

Feb 14th, 2020
174
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.34 KB | None | 0 0
  1. package com;
  2.  
  3. import java.util.Scanner;
  4.  
  5. public class MaxNumber
  6. {
  7.   public static void main(String[] args)
  8.   {
  9.     Scanner scanner = new Scanner(System.in);
  10.     int firstNumber = scanner.nextInt();
  11.     int secondNumber = scanner.nextInt();
  12.     int result = Math.max(firstNumber,secondNumber);
  13.  
  14.     System.out.println(result);
  15.  
  16.   }
  17. }
Advertisement
Add Comment
Please, Sign In to add comment