I was solving an exercise in python using Visual Studio Code, to creat a triangle with asterisks:
h = int(input('Introduce el nro de líneas para el triángulo isósceles:'))
for i in range(h):
espacios = h - i
asteriscos = 2 * i + 1
print(' ' * espacios + '*' * asteriscos)
But, when I run in Python Interactive Window, there is a problem: first line printed not considered spaces:

This same code in Jupyter Notebook or Spyder works fine.