#include using namespace std; using UL=unsigned int; using LL=long long; using ULL=unsigned long long; #define rep(i,n) for(UL i=0; i<(n); i++) inline UL F(UL a,UL b,UL c,UL d){ int x=a*a; a+=b; x+=a*b; a+=c; x+=a*c; a+=d; x+=a*d; return x; } UL A[262144]={}; UL fx; #define adA(x) fx=x; if(fx<=N) A[fx] int main(){ UL N,M; cin>>N>>M; M++; rep(a,M){ if(F(a,0,0,0)>N) break; adA(F(a,a,a,a))+=1; rep(b,a){ if(F(a,b,0,0)>N) break; adA(F(a,b,b,b))+=4; adA(F(a,a,b,b))+=6; adA(F(a,a,a,b))+=4; rep(c,b){ if(F(a,b,c,0)>N) break; adA(F(a,b,c,c))+=12; adA(F(a,b,b,c))+=12; adA(F(a,a,b,c))+=12; rep(d,c){ adA(F(a,b,c,d))+=24; else break; } } } } rep(i,N+1) printf("%u\n",A[i]); return 0; }