Example code:
#!/usr/bin/python
# -*- coding: utf-8 -*-
n = int(input('Enter number of rows: '))
for i in range(n, 0, -1):
print (n - i) * ' ' + i * '*'
Example code:
#!/usr/bin/python
# -*- coding: utf-8 -*-
n = int(input('Enter number of rows: '))
for i in range(n, 0, -1):
print (n - i) * ' ' + i * '*'