Language C
1. Please save the program with the name‘triangle.c’
Write a nested for loop that prints the following output:
1
1 2 1
1 2 4 2 1
1 2 4 8 4 2 1
1 2 4 8 16 8 4 2 1
1 2 4 8 16 32 16 8 4 2 1
1 2 4 8 16 32 64 32 16 8 4 2 1
1 2 4 8 16 32 64 128 64 32 16 8 4 2 1
Hint: Here is the psudocode solution:
for row from 0 to 7 {
pad leading blanks in a row like this
for the column from 1 to 7-row:
print
PayPal Gateway not configured
PayPal Gateway not configured