Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class ArraysPrTask2 {
- public static void main(String[] args) {
- Scanner scanner = new Scanner(System.in);
- String line = scanner.nextLine();
- String[] inputStr = line.split("");
- for (int i = inputStr.length - 1; i >= 0; i--) {
- System.out.print(inputStr[i]);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment