0% found this document useful (0 votes)
11 views1 page

Nested Loops: Triangle Patterns Lab

Uploaded by

Destiny Sumani
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views1 page

Nested Loops: Triangle Patterns Lab

Uploaded by

Destiny Sumani
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd

A+ Computer Science TRIANGLE TWO

Lab Goal : This lab was designed to teach you how to use nested loops. You will also learn how to
make some cool shapes.

Lab Description : Use nested loops to print out the triangle letter pattern show below.

Sample Data :
3 A Files Needed ::
7 X [Link]
1 R [Link]
5 T
4 W

Sample Output :
AAA
AA
A algorithm help

XXXXXXX output="";
XXXXXX loop i = 1 to size
XXXXX {
XXXX loop j = size down to i
XXX {
XX output = output + letter
X }
output = output + "\n"
}
R

TTTTT
TTTT
TTT
TT
T

WWWW
WWW
WW
W

© A+ Computer Science – Nested Loops - [Link]

You might also like