1234

Solution-4

public class Star {

public static void main(String[] args) {
for(char ch1=97;ch1<=101;ch1++)
{
for(char ch2=97;ch2<=ch1;ch2++)
{
System.out.print(ch2);
}
System.out.println("");
}

}

}

No comments:

Post a Comment