BetinaUKTC

paste

Jan 14th, 2021 (edited)
690
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import java.util.Arrays;
  2. import java.util.Collections;
  3. import java.util.Scanner;
  4.  
  5. class Main {
  6.  
  7.     public static void main(String[] args) {
  8.         Scanner scan = new Scanner(System.in);
  9.         String [] arr = scan.nextLine().split(" ");;
  10.  
  11.         Collections.reverse(Arrays.asList(arr));
  12.         System.out.println(Arrays.asList(arr));
  13.  
  14.     }
  15. }
  16.  
RAW Paste Data