Pyramid
- (Printing numbers in a pyramid pattern) 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
Posted Answers
No answers were posted yet - be the first one to answer!
Sign in to participate
Got an answer for anafarhana? Would you like to comment on the posted answers, or vote for the one which you think is the best?
Sign up for a free account, or sign in (if you're already a member).