Answer to Question #221738 in Python for Hari nadh babu

Question #221738

Half Pyramid - 3


This Program name is Half Pyramid - 3. Write a Python program to Half Pyramid - 3


The below link contains Half Pyramid - 3 question, explanation and test cases


https://drive.google.com/file/d/13c3-3LSzTDuA0PqNWXiMAZ1LoT-FBd_Q/view?usp=sharing


We need exact output when the code was run

1
Expert's answer
2021-08-04T14:11:02-0400
N = int(input())
K = int(input())


output = ''
for i in range(1, K + 1):
    for j in range(i):
        output += str(N) + ' '
        N += 1
    output += '\n'
print(output)

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS