-- 答え参照
local function xyz(x, y, z)
	return x*x + y*y + z*z + x*y + y*z + z*x
end

local N = io.read("*n")

local loop_num = math.ceil(math.sqrt(N))

local out_s = {}
for i = 1, N do
	out_s[i] = 0
end

for x = 1, loop_num do
	for y = 1, loop_num do
		for z = 1, loop_num do
			local result = xyz(x, y, z)
			if result <= N then
				out_s[result] = out_s[result] + 1
			end
		end
	end
end

print(table.concat(out_s, "\n"))