Write a program to display the pattern A B C D E F G H I J K L M N O
Write a program to display the pattern:
AB CD E FG H I JK L M N O
68 Likes
public class KboatStringPattern { public static void main(String args[]) { char ch = 'A'; for (int i = 0; i < 5; i++) { for (int j = 0; j <= i; j++) { System.out.print(ch++); } System.out.println(); } } }
Answered By
23 Likes