...

/

Solution Review: Print Pattern using Nested Loops

Solution Review: Print Pattern using Nested Loops

This review provides a detailed explanation of the solution to the "Print Pattern using Nested Loops" challenge.

Solution

Let’s go over the solution to the challenge in Powershell and Python.

Python

Press + to interact
for i in range(0, 5): # Outer loop define the number of rows
for j in range(0, i+1): # Inner loop is used to define number of column in each row
# printing stars
print("*",end="")
print("\n") # Here the programs move to the next line

Explanation

...