N, M = map(int, input().split()) res = [0] * (N + 1) for a in range(M + 1): a_ = a ** 2 for b in range(a, M + 1): b_ = b * (a + b) for c in range(b, M + 1): c_ = c * (a + b + c) for d in range(c, M + 1): x = a_ + b_ + c_ + d * (a + b + c + d) if x > N: break if a == b == c == d: res[x] += 1 elif a == b == c or b == c == d: res[x] += 4 elif a == b and c == d: res[x] += 6 elif a == b or b == c or c == d: res[x] += 12 else: res[x] += 24 print(*res, sep="\n")