N = int(eval(input()))



keys = [i for i in range(1, N+1)]

values = [0] * N

count_dict = dict(list(zip(keys, values)))



for x in range(1, N//6+7):

    for y in range(x, N//6+7):

        for z in range(y, N//6+7):

            n = x**2 + y**2 + z**2 + x*y + y*z + z*x

            if n > N:

                break

            if x == y and y == z:

                count_dict[n] += 1

            elif x != y and x != z and y != z:

                count_dict[n] += 6

            else:

                count_dict[n] += 3



for v in list(count_dict.values()):

    print(v)
N = int(eval(input()))



keys = [i for i in range(1, N+1)]

values = [0] * N

count_dict = dict(list(zip(keys, values)))



for x in range(1, 110):

    for y in range(x, 110):

        for z in range(y, 110):

            n = x**2 + y**2 + z**2 + x*y + y*z + z*x

            if n > N:

                break

            if x == y and y == z:

                count_dict[n] += 1

            elif x != y and x != z and y != z:

                count_dict[n] += 6

            else:

                count_dict[n] += 3



for v in list(count_dict.values()):

    print(v)
N = int(eval(input()))
keys = [i for i in range(1, N + 1)]
values = [0] * N
count_dict = dict(list(zip(keys, values)))
for x in range(1, N // 6 + 7):
    for y in range(x, N // 6 + 7):
        for z in range(y, N // 6 + 7):
            n = x**2 + y**2 + z**2 + x * y + y * z + z * x
            if n > N:
                break
            if x == y and y == z:
                count_dict[n] += 1
            elif x != y and x != z and y != z:
                count_dict[n] += 6
            else:
                count_dict[n] += 3
for v in list(count_dict.values()):
    print(v)

N = int(eval(input()))
keys = [i for i in range(1, N + 1)]
values = [0] * N
count_dict = dict(list(zip(keys, values)))
for x in range(1, 110):
    for y in range(x, 110):
        for z in range(y, 110):
            n = x**2 + y**2 + z**2 + x * y + y * z + z * x
            if n > N:
                break
            if x == y and y == z:
                count_dict[n] += 1
            elif x != y and x != z and y != z:
                count_dict[n] += 6
            else:
                count_dict[n] += 3
for v in list(count_dict.values()):
    print(v)

-for x in range(1, N // 6 + 7): -    for y in range(x, N // 6 + 7): -        for z in range(y, N // 6 + 7): +for x in range(1, 110): +    for y in range(x, 110): +        for z in range(y, 110):