+ 1

Can someone give the java codes to make the following pattern?

1 2 3 4 5 2 3 4 5 3 4 5 4 5 5

7th Nov 2017, 3:19 PM
Amartya D
Amartya D - avatar
2 Respuestas
+ 3
for(int i = 1; i <=5; i++){ for(int j = i; j<=5; j++{ System.out.print(j + " "); } System.out.print("\n"); }
7th Nov 2017, 4:35 PM
Jeremy
Jeremy - avatar
+ 8
And why do I need to do that?
7th Nov 2017, 3:24 PM
qwerty
qwerty - avatar