0
Square with numbers
help to display the following figure: 1 2 * * * * * * * * * * * * * * * * 3 4 https://code.sololearn.com/cZvwE65Tpufu/?ref=app here is my attempt
3 Answers
+ 5
I will not give answer, coz it was given by AJ sir,
But I can suggest you to use for loop, coz for loop is used for those iteration whom you know how much time you wanna go.
For loop is easily readble in your case.
Using for loop - https://code.sololearn.com/cGb85TuqCWrw/?ref=app
+ 2
Best of Sport
You can add two loop above and below the star pattern.
https://code.sololearn.com/cJqo6DBe67ys/?ref=app
0
your exact code pattern unmodified except two loops additions to add digits at corners:
https://code.sololearn.com/cdcuy5ccMy9O/?ref=app