#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <bits/stdc++.h>
using namespace __gnu_pbds;
using namespace std;
#define  FIFO ios::sync_with_stdio(false); cin.tie(0);cout.tie(0)
#define  inf 2e18
#define  mod 1000000007
#define  bg begin()
#define  en end()
#define  ll long long int
#define  pb push_back
#define  mp make_pair
#define  pii pair<int,int>
#define  pll pair<ll,ll>
#define  vi vector<int>
#define  vll vector<long long int>
#define  vpll vector<pair<long long int,long long int> >
#define  vpii vector<pair<int,int> >
#define  vstr vector<string>
#define  mpii map<int ,int>
#define  mpll map<long long int,long long int >
#define  max3(a,b,ser) max(a,max(b,ser))
#define  min3(a,b,ser) min(a,min(b,ser))
#define  setbits(x)  __builtin_popcountll(x)
#define  zerobits(x) __builtin_ctzll(x) //zeros after rightmost set bit
#define  w(t) ll t; cin>>t; while(t--)
#define  vin(v,m) for(int i=0;i<m;i++){ll x;cin>>x; v.pb(x);}
#define  for0(i,m) for(int i=0;i<m;i++)
#define  for1(i,m) for(int i=1;i<=m;i++)
#define  forn(i,a,b) for(int i=a;i<=b;i++)
#define  forv(it,v) for(auto it=v.begin();it!=v.end();it++)
#define  mem(a,val) memset(a,val,sizeof(a))
#define  Sort(vec) sort(vec.begin(),vec.end())
#define  RSort(vec) sort(vec.rbegin(),vec.rend())
#define  eb emplace_back
#define  bs binary_search
#define  lb(v,a) lower_bound(v.begin(),v.end(),a)
#define  ub(v,a) upper_bound(v.begin(),v.end(),a)
#define  deb1(x) cerr<<#x<<": "<<x<<" "<<endl
#define  deb2(x, y) cerr<<#x<<": "<<x<<" | "<<#y<<": "<<y<<endl
#define  deb3(x, y, z) cerr<<#x<<":" <<x<<" | "<<#y<<": "<<y<<" | "<<#z<<": "<<z<<endl
#define  deb4(a, b, ser, d) cerr<<#a<<": "<<a<<" | "<<#b<<": "<<b<<" | "<<#ser<<": "<<ser<<" | "<<#d<<": "<<d<<endl
#define  FF first
#define  SS second
#define  yes "YES"
#define  no "NO"
#define  PI 3.141592653589793238462643383279502884L
#define  printv(v) for(auto it=v.bg;it!=v.en;it++) cout<<*it<<" "<<endl;
// find_by_order(p)  returns iterator to kth element starting from 0;
// order_of_key(p) returns count of elements strictly smaller than p;
//order of key returns the index if the element was present.
template <typename T>
using orderedset = tree<T, null_type, less<T>, rb_tree_tag, tree_order_statistics_node_update>;
ll Ceil(ll a, ll b) {return a / b + (a % b != 0);}
ll fastModExp(ll a, ll b) { ll res = 1; while (b > 0) {if (b & 1)res = (res * a) % mod; a = (a * a) % mod; b = b >> 1;} return res;}
ll Logn(ll m, ll r) {return (m > r - 1) ? 1 + Logn(m / r, r) : 0;}
// 2- Dimensional vector:- vector<vector<int> > v(m, vector<int> (26, 0));
// Add mod when using mod(avoid -)



int main()
{
    int n;
    cin >> n;
    //ll dp[n + 1] = {0};

    for (int m = 1; m <= n; m++)
    {
        ll count = 0;
        //map<pii, int> mpx1;
        int nn = sqrt(m);
        int min = (nn + 1) / sqrt(3);
        int min1 = (nn + 1) / sqrt(2);
        for (int i = 1; i <= min; i++)
        {
            for (int j = i; j <= min1; j++)
            {
                for (int k = j; k <= nn; k++)
                {
                    if (i * i + j * j + k * k + i * j + j * k + i * k == m)
                    {
                        if ( (i == j && j == k)) {
                            //     mpx1[ {m, i}] = 1;
                            //     mpx1[ {m, j}] = 1;
                            //     mpx1[ {m, k}] = 1;
                            //deb4(m, i, j, k);
                            count += 1;
                        }

                        else if ( ((i == j) || (j == k) || (i == k))) {
                            //deb4(m, i, j, k);

                            count += 3;
                        }
                        else if ( (i != j && j != k && i != k)) {

                            count += 6;
                        }
                    }
                }
            }
        }
        cout << count << endl;
    }
    return 0;
}

Measured memory_bytes: 3640