print like this in java
111
222
333
Answers
Answered by
1
Solution.
Here, I have assumed that the number of rows for the pattern is fixed.
Coming to program -
public class Pattern{
public static void main(String s[]){
for(int i=1;i<=3;i++){
for(int j=1;j<=3;j++)
System.out.print(i);
System.out.println();
}
}
}
Output.
111
222
333
See attachment for verification.
Attachments:
Similar questions
Math,
11 days ago
English,
11 days ago
Math,
22 days ago
India Languages,
22 days ago
Physics,
8 months ago