I'm trying to recreate this shape (image below) using Python but I have some difficulties with the spaces.
This is the code that I have so far.
def shape(n):
for i in range(0,n):
for j in range(0,i+1):
print("*",end="")
print("")
for i in range(n,0,-1):
for j in range(0,i-1):
print("","*",end="")
print("")
shape(10)
