Advertisement
veronikaaa86

05. Character Sequence

Mar 19th, 2022
182
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. package forLoops;
  2.  
  3. import java.util.Scanner;
  4.  
  5. public class P05CharacterSequence {
  6. public static void main(String[] args) {
  7. Scanner scanner = new Scanner(System.in);
  8.  
  9. String text = scanner.nextLine();
  10.  
  11. for (int i = 0; i < text.length(); i++) {
  12. char symbol = text.charAt(i);
  13.  
  14. System.out.println(symbol);
  15. }
  16. }
  17. }
  18.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement