Triangle

Report a typo

Draw a triangle of a given height, as in the example.

Tip: Make use of the str.center(length) method that centers a string and fills the missing space on both sides with spaces.

Sample Input 1:

3

Sample Output 1:

  #  
 ### 
#####
Write a program in Python 3





___

Create a free account to access the full topic