Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

Number pyramid pattern in python

# pyramid number pattern
n = 5
for i in range(n):
    for j in range(n - i - 1):
        print(' ', end='')
    for k in range(2 * i + 1):
        print(k + 1, end='')
    print()
Source by www.tutorialstonight.com #
 
PREVIOUS NEXT
Tagged: #Number #pyramid #pattern #python
ADD COMMENT
Topic
Name
9+7 =