Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static void main(String[] args) {
- Scanner scan = new Scanner(System.in);
- System.out.print("Mata in två heltal: ");
- int tal1 = scan.nextInt();
- int tal2 = scan.nextInt();
- int max = tal1 > tal2 ? tal1 : tal2;
- System.out.println("Det största talet är " + max);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement