Full Pyramid

#include <stdio.h>
int main ()
{
int N, i, j, k;

scanf(“%d”, &N);

for (i=1; i<=N; i++){
for (k=N; k>i; k–){
printf(" “);
}
for (j=1; j<=i; j++){
printf(” *“);
}
printf(”\n");
}

return 0;
}

what is the problem in this code ]

What is wrong with this code?

N = int(input())
s = []
for i in range(1,N+1):
    s.append("*")
    s1 = ' '.join(s)
    print(s1.center(2*N))