0
One of the edge case
So in the pattern when you do it for n=1, it prints 2 stars when it should just print 1 star. So any solutions to solve that?! https://code.sololearn.com/cGmERVak3oZ0/?ref=app
2 Respuestas
+ 4
Hi Kashish
at line 25 add a condition so to check if n > 1 then print
for(int i=1;i<=n&&n>1;i++){
System.out.print("* ");
}
+ 1
Thank you for helping