Print Pattern for Given Number of Rows

Prompt

Result