Computer Science, asked by ak6468441, 4 months ago

Python Program to print the below pattern.
1
2 1
4 2 1
8 4 2 1
16 8 4 2 1
32 16 8 4 2 1
64 32 16 8 4 2 1​

Answers

Answered by sahibsaifi12291
1

Explanation:

rows = 9

for i in range(1, rows):

for j in range(-1+i, -1, -1):

print(format(2**j, "4d"), end=' ')

print("")

Similar questions