Python Practice › Loop Programs › Program 54

Inverted right triangle of stars

EasyLoop Programs · 54 of 90

Write a Python program to print an inverted right triangle of stars with 5 rows.

Advertisement
Output
* * * * * 
* * * * 
* * * 
* * 
* 

Approach

  1. Count rows down from 5 to 1.

Solution

Python
for i in range(5, 0, -1):    print("* " * i)
Output
* * * * * 
* * * * 
* * * 
* * 
* 
Advertisement

Learn the concept

New to this topic? Read the lesson, then come back.

More loop programs

← All 90 Loop Programs