Advertisement
IrinaIgnatova

Text Processing- Shift character with 3

Jul 22nd, 2019
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.38 KB | None | 0 0
  1. package com.company;
  2.  
  3.  
  4. import java.util.*;
  5. import java.util.stream.Collectors;
  6.  
  7. public class Main {
  8.  
  9.     public static void main(String[] args) {
  10.  
  11.         Scanner scanner = new Scanner(System.in);
  12.         String text = scanner.nextLine();
  13.         for (Character symbol : text.toCharArray()) {
  14.             System.out.print((char) (symbol + 3));
  15.         }
  16.  
  17.  
  18.     }
  19.  
  20.  
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement