Welcome folks today in this blog post we will be
printing simple number triangle pattern using for loop in python.All the full source code of the application is given below.
In order to get started you need to make an
app.py file and copy paste the following code
Printing Number Triangle
rows = 6 for num in range(rows): for i in range(num): print(num,end="") # print number # line after each row to display pattern correctly print("")
Now if you execute the
python script by typing the below command as shown below