+ 1

Help me with a code

Fix me this code: print (* ** *** ****), and make a triangle out of these stars by using \n newline to create line breaks in the strings. Remove any extra spaces to match the required output.

4th Sep 2021, 11:31 AM
prince herve
prince herve - avatar
2 Answers
+ 3
Star is not a number. It is a charachter. More of them is a string. That means you need to code in this way: print("*\n**\n***\n****") I would like to recommend you to complete the python tutorial here on SoloLearn.
4th Sep 2021, 11:37 AM
JaScript
JaScript - avatar
+ 2
print("*\n**\n***\n****" )
4th Sep 2021, 11:35 AM
TWO X
TWO X - avatar