Buggy python submission (verdict: Time Limit Exceeded):
N=int(input())
for n in range(1,N+1):
    s=0
    for x in range(1,41):  
        for y in range(x,41):
            for z in range(y,41):
                fn=(x+y)*(x+y)+(y+z)*(y+z)+(z+x)*(z+x)
                if fn==2*n:
                    if x==y:
                        if x==z:
                            s=s+1
                        else:
                            s=s+3
                    else:
                        if y==z:
                            s=s+3
                        else:
                            s=s+6    
    print(s)     

Fixed submission:
N=int(input())
ans=[0]*(N+1)
for x in range(1,101):  
    for y in range(1,101):
        for z in range(1,101):
            fn=x**2+y**2+z**2+x*y+y*z+z*x
            if fn>N:
                break
            else:
                ans[fn]=ans[fn]+1
for n in range(1,N+1):
    print(ans[n])

Buggy python submission (verdict: Time Limit Exceeded):
N=int(input())
for n in range(1,N+1):
    s=0
    for x in range(1,41):  
        for y in range(x,41):
            for z in range(y,41):
                fn=x*x+y*y+z*z+x*y+y*z+z*x
                if fn==n:
                    if x==y:
                        if x==z:
                            s=s+1
                        else:
                            s=s+3
                    else:
                        if y==z:
                            s=s+3
                        else:
                            s=s+6    
    print(s)  

Fixed submission:
N=int(input())
ans=[0]*(N+1)
for x in range(1,101):  
    for y in range(1,101):
        for z in range(1,101):
            fn=x**2+y**2+z**2+x*y+y*z+z*x
            if fn>N:
                break
            else:
                ans[fn]=ans[fn]+1
for n in range(1,N+1):
    print(ans[n])

Buggy python submission (verdict: Time Limit Exceeded):
N=int(input())
for n in range(1,N+1):
    s=0
    for x in range(1,41):  
        for y in range(x,41):
            for z in range(y,41):
                fn=x*x+y*y+z*z+x*y+y*z+z*x
                if fn==n:
                    if x==y and x==z:
                        s=s+1
                    if x<y and y==z:
                        s=s+3
                    if x==y and y<z:
                        s=s+3              
                    if x<y and y<z:
                        s=s+6    
    print(s)      

Fixed submission:
N=int(input())
ans=[0]*(N+1)
for x in range(1,101):  
    for y in range(1,101):
        for z in range(1,101):
            fn=x**2+y**2+z**2+x*y+y*z+z*x
            if fn>N:
                break
            else:
                ans[fn]=ans[fn]+1
for n in range(1,N+1):
    print(ans[n])

Buggy python submission (verdict: Time Limit Exceeded):
N=int(input())
for n in range(1,N+1):
    s=0
    for x in range(1,50):  
        for y in range(x,50):
            for z in range(y,50):
                fn=x*x+y*y+z*z+x*y+y*z+z*x
                if fn==n:
                    if x==y and x==z:
                        s=s+1
                    if x<y and y==z:
                        s=s+3
                    if x==y and y<z:
                        s=s+3              
                    if x<y and y<z:
                        s=s+6    
    print(s)    

Fixed submission:
N=int(input())
ans=[0]*(N+1)
for x in range(1,101):  
    for y in range(1,101):
        for z in range(1,101):
            fn=x**2+y**2+z**2+x*y+y*z+z*x
            if fn>N:
                break
            else:
                ans[fn]=ans[fn]+1
for n in range(1,N+1):
    print(ans[n])

Buggy python submission (verdict: Time Limit Exceeded):
N=int(input())
for n in range(1,N+1):
    s=0
    for x in range(1,50):  
        for y in range(x,50):
            for z in range(y,50):
                fn=x*x+y*y+z*z+x*y+y*z+z*x
                if fn==n and x==y and x==z:
                    s=s+1
                if fn==n and x<y and y==z:
                    s=s+3
                if fn==n and x==y and y<z:
                    s=s+3              
                if fn==n and x<y and y<z:
                    s=s+6    
    print(s)  

Fixed submission:
N=int(input())
ans=[0]*(N+1)
for x in range(1,101):  
    for y in range(1,101):
        for z in range(1,101):
            fn=x**2+y**2+z**2+x*y+y*z+z*x
            if fn>N:
                break
            else:
                ans[fn]=ans[fn]+1
for n in range(1,N+1):
    print(ans[n])

Buggy python submission (verdict: Time Limit Exceeded):
N=int(input())
for n in range(1,N+1):
    s=0
    for x in range(1,101):
        for y in range(x,101):
            for z in range(y,101):
                fn=x*x+y*y+z*z+x*y+y*z+z*x
                if fn==n and x==y and x==z:
                    s=s+1
                if fn==n and x<y and y==z:
                    s=s+3
                if fn==n and x==y and y<z:
                    s=s+3              
                if fn==n and x<y and y<z:
                    s=s+6    
    print(s)    

Fixed submission:
N=int(input())
ans=[0]*(N+1)
for x in range(1,101):  
    for y in range(1,101):
        for z in range(1,101):
            fn=x**2+y**2+z**2+x*y+y*z+z*x
            if fn>N:
                break
            else:
                ans[fn]=ans[fn]+1
for n in range(1,N+1):
    print(ans[n])