Write a program in java to display the given pattern: 11111 3333 555 77 9
Answers
Answered by
10
Answer:
You can change package, class name, etc. of your own.
Explanation:
package com.company;
public class Main
{
public static void main (String ar [])
{
for(int I=1 ; I<=9; I +=2)
{
for(int j=9 ; j>=I; j -=2)
{
System.out.print(I);
}
System.out.println();
}
}
}
Answered by
3
Answer:
pls check the attachment.
Explanation:
do the dry run for better understanding
Attachments:
Similar questions