How to draw a hollow inverted triangle in phython with equal sides and equal symbols
totalrows = int(input("Enter the number of rows: "))
for row in range(1, totalrows+1):
for space in range(1, (totalrows-row)+1):
print(" ", end="")
for symbol in range(1, row+1):
print("* ", end="")
print()
Comments
Leave a comment