varikutisrinivas123 n=5 k=3 for i in range(1,n+1): z=k for j in range(i): print(z,end=””) z-=1 print() if i!=n: k=k+(i+1) for i in range(n,0,-1): z=k for j in range(i): print(z,end=””) z-=1 print() k=k-i Log in to Reply
n=5
k=3
for i in range(1,n+1):
z=k
for j in range(i):
print(z,end=””)
z-=1
print()
if i!=n:
k=k+(i+1)
for i in range(n,0,-1):
z=k
for j in range(i):
print(z,end=””)
z-=1
print()
k=k-i
Good
Good
9
Gud