Language: C++

#include<bits/stdc++.h>
using namespace std;

int calc(int a,int b,int c)
{
    return a*a+b*b+c*c;
}

int ans[10005]={0,0,0,0,0,0,1,0,0,0,0,3,0,0,0,0,0,3,3,0,0,0,0,0,1,6,0,3,0,0,0,0,0,3,3,6,0,0,0,0,0,0,0,3,3,6,0,6,0,0,0,0,0,0,1,6,0,6,6,0,0,6,0,0,0,0,0,3,3,6,0,6,3,6,0,0,0,0,0,0,0,3,3,6,0,6,3,6,0,3,6,0,0,0,0,0,1,6,0,6,6,0,0,12,0,6,0,0,0,0,0,0,0,3,3,6,0,6,3,6,0,3,6,6,0,6,0,0,0,0,0,3,3,6,0,6,3,6,0,3,6,6,0,6,0,6,0,6,0,0,1,6,0,6,6,0,0,12,0,6,0,0,6,12,0,0,6,0,0,0,0,3,3,6,0,6,3,6,0,3,6,6,0,6,0,6,0,9,6,0,0,6,0,3,3,6,0,6,3,6,0,3,6,6,0,6,0,6,0,9,6,0,0,6,0,0,1,6,0,6,6,0,0,12,0,6,0,0,6,12,0,0,6,0,0,12,0,12,0,0,0,9,3,6,0,6,3,6,0,3,6,6,0,6,0,6,0,9,6,0,0,6,3,6,0,6,6,9,3,6,0,12,3,6,0,3,6,6,0,6,0,6,0,9,6,0,0,6,3,6,0,6,6,6,1,6,0,12,6,0,0,12,0,6,0,0,6,12,0,0,6,0,0,12,0,12,0,0,0,6,0,6,12,3,3,18,0,6,3,6,6,3,6,6,0,6,0,6,0,9,6,0,0,6,3,6,0,6,6,6,0,0,0,15,3,12,0,6,3,12,0,3,6,6,0,12,0,6,0,9,6,0,0,6,3,6,0,6,6,6,0,0,0,12,1,12,3,12,6,6,6,12,0,6,0,6,6,12,0,0,6,0,0,12,0,12,0,0,0,6,0,6,12,0,0,12,0,3,3,6,6,18,3,18,0,3,6,18,0,6,0,6,0,15,6,0,0,6,3,6,0,6,6,6,0,0,0,12,0,6,3,9,3,12,6,6,3,9,6,9,6,12,0,6,0,6,6,9,6,0,0,6,3,6,0,6,6,6,0,0,0,12,0,6,3,6,1,12,6,6,6,3,6,18,0,18,0,6,6,12,6,6,6,0,0,12,0,18,0,0,0,6,0,6,12,0,0,12,0,0,0,0,6,15,3,18,0,6,3,18,0,3,6,6,3,18,0,6,6,9,6,0,0,12,3,6,0,6,6,6,6,0,0,12,0,6,3,6,0,6,6,3,3,9,6,12,3,18,0,9,6,6,6,12,0,12,0,15,6,6,0,12,3,6,0,6,6,12,0,0,0,12,0,6,3,6,0,6,6,0,1,9,6,12,6,12,0,18,0,6,6,6,6,18,0,6,6,9,6,18,0,18,0,0,0,12,6,6,12,0,0,12,0,6,0,0,6,12,0,12,0,3,3,18,0,6,3,6,6,21,6,6,12,6,0,6,0,21,6,0,0,12,3,12,6,6,6,12,0,0,0,12,0,12,3,6,0,6,6,0,0,3,6,9,3,18,0,12,3,6,6,9,6,12,0,12,0,15,6,15,6,6,0,6,3,12,9,12,6,6,6,0,0,18,0,12,3,6,0,6,6,0,6,3,6,6,1,18,0,12,6,0,6,18,0,12,0,6,6,21,6,6,6,6,0,12,0,18,6,0,0,6,0,12,12,12,0,12,0,6,0,0,6,12,6,18,0,0,0,12,0,3,3,12,6,24,3,6,12,3,6,6,0,18,0,6,0,21,6,12,6,6,3,18,0,6,6,6,0,12,0,15,6,6,3,12,0,12,6,0,6,3,6,6,0,12,0,15,3,6,6,12,3,12,0,9,6,15,6,12,0,12,0,9,6,6,9,12,3,6,6,12,6,18,0,6,0,18,0,6,3,12,6,18,6,0,0,9,6,6,0,18,0,12,1,6,6,12,6,6,0,24,0,15,6,6,6,18,0,0,6,6,9,18,0,12,6,6,0,18,0,12,12,6,0,12,0,0,6,6,6,12,3,18,0,0,6,18,0,0,0,6,6,21,3,6,12,6,9,6,0,15,6,6,0,18,0,24,6,9,6,12,0,6,3,6,0,18,6,12,12,0,0,24,0,12,3,6,12,6,6,0,0,3,6,24,0,18,0,6,0,6,6,9,9,12,0,18,3,15,6,9,6,12,0,12,0,12,9,15,6,0,6,12,3,18,0,12,6,12,0,0,0,18,6,18,3,6,0,12,6,0,0,9,6,12,0,12,0,9,6,0,6,18,7,12,0,12,12,9,6,18,0,18,0,6,6,18,9,6,6,0,6,18,6,24,0,6,0,12,0,6,12,6,6,24,0,0,3,12,6,12,6,18,0,6,0,18,0,0,0,0,6,24,6,6,12,9,3,6,0,24,3,12,0,15,6,24,6,6,0,18,0,9,6,6,0,18,3,12,12,6,6,18,0,6,0,12,12,6,3,6,0,6,6,24,0,15,6,6,0,24,0,6,6,0,6,18,0,6,0,9,6,21,6,24,9,12,0,3,6,18,9,12,0,12,6,15,12,12,0,12,3,12,0,6,6,18,6,12,0,12,3,18,3,6,6,12,6,6,0,9,6,9,6,12,0,18,6,0,6,6,6,6,0,6,1,21,6,18,6,12,0,18,0,12,9,12,12,12,6,6,6,18,0,18,0,18,0,0,0,18,6,18,12,0,3,24,0,0,6,12,6,18,0,18,0,3,6,12,0,12,6,6,6,24,6,0,12,6,0,6,0,21,3,12,0,18,3,18,6,6,18,24,0,12,0,6,0,21,12,6,12,12,3,18,0,18,6,6,12,0,0,12,0,6,9,30,0,18,6,0,0,15,6,6,6,12,0,18,0,0,6,6,3,12,0,18,6,9,6,9,3,18,0,6,3,18,9,9,12,6,6,18,0,24,0,15,6,24,0,6,3,12,6,24,6,6,3,12,6,12,6,18,3,12,0,12,6,3,6,3,6,24,6,18,0,12,6,0,6,12,0,12,0,12,0,21,6,12,1,12,0,12,12,12,9,18,0,12,6,6,6,24,0,12,9,18,0,12,6,18,6,12,0,12,3,24,12,0,6,18,6,6,0,6,6,15,6,12,0,18,6,18,0,6,6,0,6,24,0,6,12,6,0,12,0,18,0,0,0,24,15,24,6,12,3,24,0,3,12,6,0,24,0,18,12,15,6,12,0,18,3,12,12,12,12,12,0,0,0,36,0,24,3,6,0,24,6,0,6,9,6,18,0,12,0,6,6,12,6,24,12,6,0,6,0,21,6,6,0,12,0,3,15,12,9,18,3,12,6,9,6,36,0,12,0,12,0,15,6,6,6,18,9,6,3,27,12,6,6,12,0,18,0,12,9,15,6,6,6,12,6,15,6,12,6,12,0,18,0,6,12,12,0,18,0,12,0,9,6,15,12,18,0,6,1,18,9,12,12,0,6,24,3,30,0,12,12,18,0,0,6,12,6,30,6,12,3,12,6,6,6,12,12,12,0,30,0,9,6,6,6,24,6,18,0,12,6,12,6,6,0,6,6,30,0,12,12,6,0,0,0,21,12,12,0,18,0,18,6,3,9,18,0,12,3,12,0,21,6,12,12,12,0,24,0,21,12,6,12,6,3,6,0,12,6,30,0,18,0,18,0,24,6,12,6,6,12,12,0,3,12,18,6,24,0,18,12,0,12,6,0,18,0,12,0,15,6,12,12,6,0,12,0,18,9,9,3,30,12,12,3,18,0,21,6,12,0,6,6,12,6,36,12,0,3,24,3,6,6,12,12,24,0,6,0,15,6,12,3,18,6,12,6,18,6,9,12,12,0,24,0,12,0,12,6,18,0,12,0,15,12,15,6,18,0,12,0,0,6,6,9,12,4,24,6,18,12,12,0,24,0,24,0,6,12,30,6,12,12,0,3,30,0,18,6,18,0,18,0,24,12,3,6,12,0,18,6,6,12,24,6,12,0,12,0,21,6,6,0,18,6,30,0,6,18,9,12,6,0,18,0,12,0,12,6,18,6,6,3,24,6,9,9,6,0,24,3,24,12,9,12,30,0,12,6,6,12,15,6,0,0,12,3,36,0,24,9,12,0,12,6,12,6,6,9,30,0,6,6,0,6,15,12,18,12,12,0,12,0,18,6,18,0,12,0,12,12,9,6,18,0,30,6,0,0,30,9,6,0,6,6,21,3,18,0,18,9,12,0,27,18,12,6,30,0,6,3,21,18,12,6,18,3,12,0,24,6,9,6,0,0,36,6,18,15,12,6,12,6,6,0,9,6,18,0,36,0,12,0,0,6,21,12,12,3,18,0,15,18,6,6,12,0,12,3,18,9,12,6,0,12,12,1,36,0,18,12,12,0,18,6,12,6,18,6,18,3,24,6,6,12,30,0,18,0,6,0,15,6,6,18,18,6,18,0,12,6,3,12,18,0,24,0,12,0,30,6,12,0,0,6,27,12,12,12,6,0,12,6,12,6,6,6,24,3,24,6,12,6,12,0,12,0,24,0,21,9,18,12,6,9,24,0,15,6,12,18,18,0,12,0,27,9,30,0,18,9,12,0,18,12,18,6,6,0,30,0,6,9,6,6,18,6,18,12,15,6,18,0,24,0,12,0,6,6,6,12,18,6,18,0,21,6,6,0,36,0,0,0,9,15,24,0,6,6,12,6,12,6,27,15,12,0,18,3,18,6,21,18,18,3,18,0,6,12,27,6,6,0,12,3,33,6,18,18,24,6,18,0,18,6,6,3,24,0,24,6,6,6,15,6,24,0,12,3,21,12,6,18,12,0,24,0,12,6,9,6,12,3,18,6,6,6,18,9,12,0,12,6,24,6,24,0,6,7,18,0,18,6,12,12,42,0,12,3,24,9,18,6,12,12,12,0,24,6,27,6,0,0,30,6,15,24,6,6,18,0,12,0,12,12,30,0,24,0,6,0,18,0,9,12,12,12,24,0,12,18,6,6,0,0,24,3,12,0,24,6,24,6,6,0,24,0,6,6,12,0,12,6,6,21,15,3,24,6,30,3,12,12,21,9,12,0,6,6,42,6,27,12,12,0,18,3,12,6,15,18,18,0,6,0,24,6,30,9,30,18,6,6,6,0,21,6,6,0,30,6,6,12,6,12,18,0,24,0,6,0,36,12,12,0,18,0,18,0,6,15,6,6,0,6,24,12,18,6,24,0,6,0,3,15,24,12,24,3,12,3,27,6,18,6,12,0,36,0,33,18,3,6,18,3,18,6,18,6,24,12,12,0,18,0,12,3,30,0,18,9,12,0,3,18,15,12,30,0,24,0,6,6,6,6,6,6,12,3,33,6,12,6,12,0,24,0,24,9,12,6,12,6,12,6,12,12,18,0,12,0,12,1,18,6,36,9,6,3,36,6,15,12,6,12,42,0,6,6,9,12,15,12,24,12,12,0,30,6,18,18,18,0,18,0,12,6,18,6,18,0,30,6,9,12,24,6,18,0,12,6,24,6,0,12,12,3,24,0,24,12,0,0,18,0,30,6,6,6,18,9,12,6,0,6,24,0,12,12,18,0,18,0,21,6,18,18,12,9,12,0,3,12,42,0,24,0,18,0,30,18,6,6,18,3,24,6,18,12,24,6,12,0,30,12,12,3,12,0,36,12,0,0,15,12,12,12,24,0,24,0,15,12,12,6,48,0,12,0,15,12,18,0,12,0,0,6,12,15,30,12,0,6,30,0,12,6,12,12,24,0,0,0,18,6,33,3,12,3,24,3,24,6,21,18,12,0,30,0,15,12,9,6,24,9,30,3,18,12,6,6,24,0,12,6,36,0,18,21,18,6,18,6,21,12,9,6,12,0,24,12,6,6,18,6,12,3,18,0,30,12,15,6,12,0,24,0,12,6,12,21,12,6,6,6,12,0,18,0,24,0,12,0,24,3,15,12,12,7,24,3,18,12,12,12,18,0,18,6,9,18,27,6,6,6,18,6,30,6,30,12,0,0,24,0,36,12,6,0,42,6,12,0,6,12,33,12,24,0,12,0,27,6,12,12,18,6,30,3,12,18,6,6,12,0,18,0,18,9,36,6,18,12,6,6,18,6,12,0,6,0,24,0,18,18,18,3,24,0,12,6,6,12,9,9,24,0,12,3,42,6,24,18,6,6,24,0,18,6,21,12,24,0,6,3,24,6,30,6,18,12,12,6,15,6,30,9,18,0,18,6,6,24,6,12,24,0,48,0,18,0,24,12,6,0,12,0,18,6,15,12,18,6,6,0,24,12,6,15,30,0,6,6,6,12,36,0,12,0,12,0,18,6,6,6,18,0,18,3,33,15,12,12,24,3,12,9,21,6,27,12,18,0,18,6,21,6,24,6,12,9,30,6,12,24,12,0,24,0,30,0,12,3,15,18,24,18,12,0,21,6,12,12,12,0,36,3,30,6,12,6,24,0,18,0,33,18,24,6,12,0,0,6,6,9,30,0,6,6,30,6,21,6,18,3,30,0,6,6,12,12,12,6,12,9,12,1,30,6,15,18,12,0,24,0,15,12,12,12,42,6,24,6,12,6,24,0,24,0,18,6,18,0,24,18,12,0,24,0,21,18,9,12,24,0,36,0,6,9,24,6,6,9,18,6,30,6,12,21,18,0,18,6,24,12,6,6,24,6,18,6,6,6,36,6,24,0,12,0,30,3,12,12,6,12,24,0,18,6,18,18,12,0,6,6,6,15,48,0,24,3,12,0,27,12,30,6,12,0,30,0,15,12,3,12,36,9,24,12,12,12,12,12,24,0,18,0,21,9,18,12,24,6,18,0,15,12,6,6,48,0,12,0,12,15,36,0,6,6,24,6,9,12,36,12,18,0,18,0,18,15,12,18,24,6,12,0,12,0,24,0,6,0,12,0,30,12,30,12,0,12,30,0,6,12,15,3,24,0,30,3,15,6,9,6,36,12,12,6,30,6,9,24,6,0,30,3,24,6,30,6,18,0,0,12,27,18,24,3,12,0,18,6,24,6,21,6,18,3,48,0,18,6,0,18,24,0,18,0,21,12,15,6,30,12,6,0,18,6,18,21,24,0,30,6,24,3,18,12,6,6,18,6,0,12,48,6,12,0,6,3,15,12,0,18,18,1,24,0,42,12,21,6,18,0,36,6,12,12,24,6,12,12,6,0,30,6,30,12,18,0,18,0,15,18,15,15,48,0,12,6,6,12,24,6,24,0,6,3,36,9,18,12,0,12,30,0,12,18,18,12,18,0,18,6,12,6,30,0,30,6,18,6,24,0,18,3,12,0,36,6,18,18,6,6,30,6,12,0,18,12,3,12,0,0,6,0,48,0,33,15,24,0,18,3,15,12,15,6,30,0,18,6,6,18,33,12,24,12,18,3,18,6,27,12,12,0,24,0,18,18,12,9,24,0,36,6,6,0,39,15,30,0,12,6,24,0,6,12,24,12,12,0,24,18,27,12,24,0,12,0,6,12,18,9,18,3,18,6,36,6,18,6,12,0,30,9,24,12,18,12,24,6,0,3,18,6,24,6,24,0,24,6,9,3,21,6,12,9,30,6,15,30,12,12,30,0,36,0,21,6,12,6,18,15,18,0,24,6,15,12,12,0,48,0,36,3,6,6,18,12,12,3,15,18,33,12,12,0,24,6,12,6,24,12,12,0,24,6,15,18,18,0,36,0,12,0,18,21,18,9,12,12,6,6,42,0,12,6,24,0,6,0,18,18,15,12,18,3,48,0,6,6,30,12,30,0,12,1,27,6,12,6,12,6,42,6,30,18,12,12,24,0,12,6,12,3,45,6,30,6,18,0,33,12,18,24,6,0,36,0,0,12,12,15,30,3,24,6,12,12,18,6,30,0,18,6,30,6,30,18,6,12,12,0,24,0,6,0,48,0,24,6,24,3,30,6,12,6,6,9,18,6,30,18,0,0,30,0,18,24,12,12,18,0,12,6,12,12,45,6,18,0,12,0,33,3,12,18,24,9,18,0,21,18,18,12,24,0,24,12,12,12,6,6,48,3,18,0,30,12,12,12,6,0,36,0,24,18,18,0,36,12,12,6,3,12,30,6,24,0,6,6,18,12,30,12,12,0,30,3,21,6,18,18,30,0,12,0,18,21,30,0,0,15,12,6,42,6,18,18,12,0,18,0,30,6,18,0,18,9,24,0,9,12,18,6,24,0,24,6,21,18,15,21,30,6,30,3,42,12,3,6,18,0,18,12,12,6,45,6,12,0,24,9,39,12,24,6,18,0,18,0,27,12,12,15,36,9,18,6,12,18,3,6,30,0,24,0,36,6,12,18,6,6,36,0,18,6,21,18,18,0,12,6,24,3,42,9,12,6,12,6,6,12,30,12,12,0,24,0,27,18,6,6,36,0,18,3,24,6,24,6,12,0,18,0,24,3,21,18,12,13,18,6,18,12,24,9,36,0,18,6,9,24,36,0,36,6,12,0,30,6,27,18,12,0,12,0,18,21,12,12,18,12,24,3,18,12,36,6,24,0,6,12,42,6,18,6,12,6,42,6,0,12,18,0,24,0,42,0,12,12,30,3,18,15,6,6,42,6,3,24,12,0,24,0,24,12,15,18,24,6,12,0,9,18,24,6,30,0,6,0,30,12,36,6,6,0,30,6,12,12,9,9,30,0,30,9,12,12,36,12,30,12,42,0,24,0,21,18,12,0,18,3,18,12,18,15,42,6,12,6,18,6,48,9,24,0,12,6,12,0,15,12,18,9,36,0,36,18,6,12,24,0,18,0,24,12,27,12,18,6,6,9,18,6,24,15,6,0,30,6,24,12,24,0,30,0,18,6,6,6,21,12,42,0,12,3,18,0,18,18,18,6,30,0,12,18,21,12,12,0,24,6,21,3,12,12,18,21,18,0,42,12,18,0,24,0,48,0,27,12,18,18,36,3,36,6,18,18,18,18,6,0,30,3,18,9,30,6,6,6,24,0,27,24,18,12,54,0,12,6,0,18,24,0,18,6,24,0,45,12,18,9,18,0,6,6,24,21,6,12,24,6,36,0,24,0,21,12,18,0,12,0,36,6,30,9,18,3,18,6,18,24,12,0,18,0,18,6,3,12,36,18,18,18,12,1,30,6,27,12,18,0,48,0,18,12,12,12,18,0,18,12,15,18,42,9,48,0,6,6,18,6,18,18,24,15,36,0,6,6,18,12,48,0,30,0,12,6,30,6,18,6,6,6,36,0,12,18,18,0,
18,9,39,21,18,6,24,6,18,6,6,12,42,0,6,0,18,6,21,12,21,18,12,0,24,0,30,12,12,24,12,0,18,0,12,0,42,6,36,12,0,0,42,6,6,12,12,0,30,0,30,15,18,6,36,3,42,12,3,12,27,6,30,0,18,6,33,15,12,24,12,12,36,0,18,18,24,0,36,0,30,3,30,15,30,12,18,12,6,6,9,6,42,12,18,0,42,6,6,12,12,18,30,9,12,0,33,18,24,6,6,0,6,0,42,9,30,18,6,12,36,0,21,6,18,0,36,0,18,0,12,18,24,0,24,9,18,6,24,12,12,24,6,0,30,6,15,12,9,6,18,6,36,12,12,6,21,9,24,0,18,3,51,6,39,6,24,6,18,0,27,24,21,24,24,0,12,3,12,6,6,12,30,3,30,0,48,12,18,15,18,0,42,6,18,6,21,24,12,6,18,6,12,6,48,6,24,0,18,0,18,9,21,18,18,6,24,0,24,12,18,9,24,0,36,6,21,15,30,6,12,6,18,0,18,6,42,18,12,0,12,3,24,12,0,12,42,12,12,12,18,6,27,6,18,0,24,6,21,6,12,18,30,7,30,0,18,12,12,6,42,0,24,0,18,15,51,12,18,12,12,12,36,12,30,6,6,0,36,3,30,24,18,6,30,0,24,0,15,12,24,6,30,0,24,6,36,12,21,18,6,15,42,0,24,18,12,9,24,0,18,6,18,6,24,6,42,18,0,0,21,6,21,18,18,0,24,0,12,24,24,6,36,0,24,6,18,24,24,0,0,0,24,6,30,6,24,12,12,0,36,0,24,6,3,6,42,0,18,0,15,12,33,9,30,18,12,6,12,18,27,21,24,0,18,6,30,12,9,18,30,3,36,9,12,12,48,12,18,0,12,0,48,0,12,3,18,12,30,6,30,18,15,18,42,0,30,9,12,18,30,12,12,0,12,0,42,6,21,12,24,0,48,6,24,12,15,15,24,0,12,12,12,0,42,12,30,0,12,0,12,6,36,12,18,12,18,3,33,24,0,12,30,0,24,0,30,6,9,6,12,12,30,6,30,0,15,18,6,0,48,6,21,9,12,12,42,3,24,0,3,24,39,12,24,0,30,3,27,6,24,18,12,3,30,3,36,24,24,6,30,0,30,6,36,15,12,12,18,12,6,6,45,6,18,6,18,0,24,0,6,21,24,9,30,6,42,6,27,12,30,9,36,0,0,6,30,15,9,12,18,6,18,0,30,12,30,18,24,0,0,6,12,12,48,0,12,21,24,6,12,6,24,6,12,0,36,6,21,18,15,6,24,6,30,0,12,12,18,6,24,0,12,1,24,6,42,21,24,12,24,6,27,12,12,18,60,0,12,6,0,6,45,12,36,3,24,0,30,6,12,18,18,0,48,0,24,30,18,12,30,12,18,9,12,12,42,12,12,0,12,12,48,3,30,12,6,6,24,6,30,18,21,6,18,0,30,6,9,12,18,18,48,6,12,0,54,6,30,18,6,0,24,0,18,12,6,18,18,6,18,0,24,6,48,0,24,0,18,0,33,6,21,18,24,3,36,6,0,12,0,18,30,0,30,12,15,24,24,0,18,15,24,3,21,12,30,24,18,0,24,0,45,12,18,0,54,3,18,6,12,12,36,6,18,0,30,6,30,9,36,18,6,15,36,0,21,18,12,18,30,0,30,0,24,6,30,0,18,12,6,0,42,12,24,12,24,0,18,0,15,27,24,6,30,6,36,6,24,12,15,6,18,0,12,6,24,12,30,24,6,3,54,6,24,18,18,0,18,0,6,12,18,12,24,6,36,12,6,0,30,18,18,6,18,0,36,0,30,6,15,21,42,3,18,3,21,24,21,12,24,0,18,0,42,6,33,18,18,9,48,3,18,12,18,18,24,0,24,6,18,18,36,6,18,6,18,18,18,6,9,24,36,0,42,0,48,6,18,12,24,12,36,0,6,6,51,6,18,0,18,0,15,24,18,21,18,6,12,12,24,6,36,6,36,0,12,12,18,0,18,12,54,12,18,3,42,6,12,18,12,0,24,0,15,6,15,18,30,0,30,6,18,12,24,6,24,0,12,12,24,15,24,0,24,7,42,0,9,18,21,12,42,0,36,0,24,18,30,6,6,6,12,9,48,0,30,30,12,0,36,0,24,24,18,18,36,15,6,6,12,12,30,0,42,0,24,0,36,0,30,15,24,12,18,6,9,24,18,6,36,0,48,6,6,12,57,12,18,6,12,0,54,6,12,18,18,0,18,0,24,24,18,0,30,3,42,6,12,24,30,6,18,0,12,3,45,6,21,12,18,12,48,0,24,18,6,18,24,0,12,6,6,6,18,9,42,15,18,6,18,18,21,9,18,0,36,3,18,18,21,18,48,6,42,0,18,6,45,6,12,0,24,3,42,6,12,18,18,12,18,9,48,18,18,9,36,0,18,12,12,15,45,6,12,6,30,6,18,0,36,18,12,0,42,0,36,24,9,24,36,6,12,0,15,12,42,15,30,0,0,6,24,6,24,18,18,12,30,0,30,18,12,6,30,0,36,3,12,6,21,12,18,12,18,6,30,6,9,24,18,0,66,6,18,6,18,6,12,0,24,3,24,18,30,12,18,0,12,0,27,3,51,12,18,3,30,6,27,18,12,18,42,0,18,3,33,21,12,12,12,21,24,0,54,12,30,12,12,0,30,6,18,21,18,3,42,6,36,6,15,6,48,3,54,0,12,6,18,6,12,24,24,6,18,6,33,18,24,18,18,0,18,0,12,21,60,12,18,18,24,6,42,0,36,0,18,0,24,6,18,24,24,12,12,3,24,0,12,12,33,12,30,0,30,0,30,12,24,12,24,18,24,0,6,12,9,21,42,0,12,6,42,0,30,12,36,6,6,1,15,18,36,12,12,0,48,0,24,30,0,12,42,3,24,12,18,18,36,12,24,0,24,9,36,12,48,18,0,6,18,0,24,12,18,12,42,0,30,6,24,3,33,6,36,12,18,6,48,6,18,24,12,0,30,0,21,30,12,12,24,0,30,9,24,6,42,18,6,0,12,0,66,0,12,12,18,9,30,6,18,12,21,18,24,0,36,6,9,18,30,12,36,6,12,0,18,6,18,12,6,0,24,3,24,9,24,24,30,6,24,12,12,18,48,0,36,0,6,6,33,9,12,18,24,3,48,6,27,12,18,6,48,0,42,0,21,12,24,6,6,24,24,6,42,12,36,15,12,0,30,6,39,9,12,12,60,12,12,0,12,18,30,18,18,0,18,6,24,18,45,18,18,0,36,0,27,30,12,6,18,0,30,6,24,15,30,0,30,6,24,6,42,0,24,24,24,0,30,0,27,18,24,6,30,9,24,12,12,18,24,6,30,0,12,0,39,6,18,6,18,15,36,0,36,18,18,12,24,0,12,0,18,9,36,0,30,12,12,0,21,18,27,18,24,0,60,15,18,18,3,24,30,3,30,6,18,12,39,12,18,0,36,3,24,9,24,18,18,18,24,0,48,6,30,3,30,0,30,12,18,15,39,6,18,12,18,0,27,12,30,24,24,0,18,0,21,24,9,12,48,6,36,12,24,6,36,15,18,0,12,6,36,6,30,12,24,6,6,0,12,12,21,18,60,0,36,3,15,12,30,12,36,6,12,12,27,18,21,12,12,0,48,12,24,15,24,12,12,6,24,0,18,6,36,0,24,0,12,0,30,12,27,36,30,7,42,0,12,12,12,24,48,0,30,3,30,12,36,6,24,15,12,0,42,12,48,24,12,0,18,6,24,12,24,0,42,6,36,6,15,12,54,9,30,0,12,6,30,18,18,18,18,9,42,0,36,30,3,12,18,0,36,0,6,6,54,6,30,12,24,6,42,0,12,12,24,0,42,6,33,18,12,24,30,6,18,12,6,30,9,6,24,0,30,0,60,6,12,6,12,3,48,0,12,18,18,21,42,0,12,6,18,6,36,6,30,24,12,0,24,6,30,12,24,0,36,0,12,18,3,3,30,0,36,15,33,12,39,12,30,0,18,9,30,9,54,18,0,12,30,3,48,18,36,12,24,0,6,6,18,30,27,9,24,6,18,6,33,6,9,36,30,0,42,0,30,18,12,12,42,6,24,0,30,6,33,12,30,0,18,0,42,6,30,15,6,12,42,6,18,24,27,6,42,0,48,6,0,6,24,18,18,12,6,9,39,18,18,6,12,0,48,3,42,6,21,27,30,0,18,12,24,12,36,6,24,0,12,6,24,9,30,12,24,12,36,0,18,18,15,18,48,0,12,0,15,27,18,12,12,9,24,9,57,12,30,15,24,0,24,6,33,18,6,6,66,9,30,6,18,6,42,12,18,0,36,6,24,9,51,15,24,6,18,6,27,24,12,12,36,0,18,6,18,18,45,12,18,12,18,0,45,6,42,12,30,0,18,0,15,27,30,6,12,6,36,12,24,12,24,12,36,0,6,0,42,12,36,18,6,21,54,0,18,12,18,12,42,0,12,0,9,6,30,9,48,6,12,6,24,6,12,12,24,0,36,6,24,30,30,12,24,0,24,0,21,24,24,0,18,0,30,1,36,12,24,18,24,3,36,9,42,18,12,12,24,0,18,6,12,12,54,0,48,15,18,6,36,6,21,24,36,0,42,3,30,15,18,30,30,12,36,0,12,6,48,12,0,0,12,12,57,12,12,18,24,6,30,0,48,30,18,0,30,0,48,6,12,12,21,12,24,18,18,6,24,6,36,30,12,0,42,6,21,6,18,12,36,6,12,3,18,18,54,12,42,0,0,6,36,9,30,6,12,6,66,6,6,12,12,12,36,0,36,12,30,6,15,12,18,12,18,0,24,6,12,30,12,0,36,0,54,15,24,9,60,12,24,6,21,18,18,6,24,0,18,6,33,6,42,24,18,9,36,6,15,30,21,18,24,0,30,0,12,15,54,12,24,6,18,6,51,12,42,12,18,0,42,6,6,18,30,6,48,0,42,0,15,6,12,6,48,0,12,6,45,15,12,30,24,18,24,0,42,12,21,12,18,0,6,12,24,15,48,6,12,12,36,0,30,18,42,0,12,0,42,0,27,12,6,21,42,12,24,12,12,12,12,12,30,0,30,0,30,6,24,18,12,6,48,0,21,30,6,18,42,0,30,6,12,9,63,3,18,9,30,9,18,6,33,18,24,0,36,0,66,24,15,12,30,12,30,3,27,6,42,12,24,0,12,0,36,9,36,21,18,12,30,6,27,18,27,12,48,0,30,12,15,24,21,12,42,6,18,0,48,12,27,24,18,0,24,0,6,12,36,21,42,6,12,12,21,18,42,6,36,0,24,12,27,12,24,6,30,0,42,3,24,12,12,6,42,0,30,0,12,24,27,12,12,18,24,6,36,12,36,30,18,0,24,0,30,12,18,18,48,0,12,0,6,12,51,12,30,0,24,0,18,6,24,24,6,16,24,6,42,12,6,12,42,0,48,6,30,12,60,6,18,15,18,12,33,18,24,12,12,0,30,0,30,36,24,3,42,6,18,6,24,12,42,18,30,0,12,6,30,6,15,24,12,6,72,0,36,18,18,18,24,0,18,12,33,12,30,0,42,18,18,12,36,12,24,6,12,0,30,0,18,12,15,18,48,9,48,0,24,24,24,12,12,0,18,0,66,0,30,15,18,6,36,6,27,18,6,12,42,0,18,12,0,24,42,6,24,12,24,0,24,12,30,12,24,0,48,0,36,21,18,18,18,6,24,9,6,0,75,9,30,0,18,3,36,12,15,30,24,12,18,12,39,24,24,12,36,0,24,3,24,18,30,18,42,12,18,0,72,0,24,21,12,0,48,6,24,18,15,12,24,0,24,0,36,12,36,6,30,0,42,6,12,9,66,12,12,12,30,6,9,30,12,36,54,0,30,12,18,12,24,0,12,12,12,3,48,0,36,24,30,0,36,3,30,15,18,6,36,18,24,6,12,18,27,12,18,0,30,12,30,6,24,24,12,0,30,0,30,18,30,6,60,0,24,0,12,18,33,15,24,12,6,6,48,0,24,12,24,0,12,3,21,21,36,18,30,3,48,6,27,12,33,12,42,0,12,6,27,12,15,18,12,9,60,6,42,18,36,9,18,0,18,12,21,15,54,12,30,18,6,0,21,12,33,24,18,0,54,0,36,24,18,12,36,6,18,0,21,18,33,12,18,0,18,6,48,15,42,18,18,24,30,0,30,0,33,12,60,0,24,0,18,12,36,15,30,3,36,12,6,6,12,15,24,0,48,6,27,36,12,18,42,6,30,0,12,24,36,12,30,0,18,0,30,6,24,0,24,3,24,6,39,30,30,6,24,0,24,9,12,6,36,12,48,15,18,4,60,6,24,24,12,0,54,6,18,18,15,18,24,12,18,12,24,12,42,12,42,0,18,0,54,3,36,18,24,12,36,0,18,18,12,18,30,0,60,0,33,24,36,6,6,18,30,12,42,6,39,18,12,0,30,6,24,0,6,12,54,6,24,12,6,24,54,0,30,0,30,3,42,12,18,24,36,0,42,0,18,24,27,18,24,0,24,6,18,9,36,18,24,18,18,0,48,12,24,18,6,0,24,0,36,18,12,18,48,0,42,12,18,12,12,3,42,0,24,6,36,12,18,12,18,15,30,0,30,30,12,18,30,0,12,6,27,3,51,6,30,9,18,12,18,12,60,24,12,0,72,6,21,36,24,12,60,3,18,0,24,12,24,12,18,0,18,0,48,9,36,21,36,12,54,6,33,6,6,6,54,0,36,0,9,27,39,18,30,12,12,6,33,24,30,30,30,0,30,0,36,15,18,6,24,9,24,18,18,12,30,9,12,0,12,12,72,6,36,6,24,15,54,0,18,24,24,18,30,0,42,0,3,12,24,12,54,6,24,0,36,12,6,12,24,0,48,6,36,9,36,18,18,6,24,6,15,12,60,6,24,0,12,3,18,18,12,24,12,9,36,6,48,24,15,9,48,0,30,9,30,18,33,6,30,18,24,0,42,0,42,24,30,0,24,3,30,15,18,24,48,6,6,12,18,12,60,9,42,0,24,12,21,18,21,30,12,0,30,0,33,24,18,12,30,0,48,6,30,12,39,6,42,6,18,12,36,6,36,15,24,0,30,6,21,15,24,0,48,12,36,0,6,18,24,12,36,0,6,3,60,15,24,36,18,9,30,0,6,18,33,24,30,0,36,9,24,6,30,12,30,12,18,0,36,0,30,12,30,0,42,6,6,18,33,12,24,12,48,6,30,24,24,6,12,0,24,9,42,6,18,30,6,13,36,0,45,12,18,6,48,0,30,6,9,24,72,0,24,12,24,6,54,18,30,15,12,0,30,12,60,30,12,18,36,6,30,12,18,12,33,12,36,0,6,0,51,6,24,12,36,18,36,0,18,30,21,18,42,0,42,6,6,6,42,18,30,9,24,0,57,18,15,12,12,0,60,0,48,24,12,12,24,6,30,12,12,24,24,9,18,0,18,6,30,18,30,18,18,6,60,0,18,12,30,24,48,0,24,6,18,9,36,0,42,18,24,0,24,6,54,30,6,0,12,9,18,24,12,6,36,12,24,0,39,12,54,6,30,0,6,6,48,6,12,21,30,12,48,3,42,18,9,18,30,0,48,0,24,21,69,12,0,6,6,9,48,6,30,12,36,0,36,0,42,24,30,24,36,0,18,12,9,18,36,12,42,0,36,6,30,12,30,24,18,12,36,0,18,18,27,6,30,0,30,3,18,9,42,21,24,24,12,12,42,6,30,12,30,0,48,6,30,12,12,18,78,0,12,3,24,18,36,12,12,0,30,0,18,6,51,24,6,6,36,6,54,12,24,9,48,0,12,6,15,24,18,0,54,15,24,0,42,18,18,36,18,0,36,6,18,18,9,18,18,6,54,15,24,6,42,12,18,0,24,6,42,9,36,12,30,3,36,6,21,30,30,6,30,0,30,0,39,30,42,9,24,21,24,6,54,12,30,18,24,0,36,0,30,15,24,36,18,12,12,0,27,12,66,12,72,0,6,0,24,18,42,0,18,12,54,6,15,6,12,21,54,0,18,12,24,15,39,12,30,6,48,3,36,6,12,18,12,0,42,0,24,36,18,15,48,6,30,18,12,30,30,6,30,0,30,6,27,6,42,12,30,12,18,0,36,18,0,12,24,0,24,3,36,0,48,18,48,12,6,9,57,24,30,12,12,0,24,6,18,18,24,0,36,3,48,12,18,6,18,12,30,0,36,1,54,6,18,36,12,18,42,0,36,12,42,18,42,0,30,12,30,15,30,12,24,18,18,0,24,12,48,18,12,0,54,6,12,18,15,12,60,0,48,6,12,30,60,18,24,0,12,6,66,0,15,18,18,6,42,3,42,18,24,24,42,0,42,6,21,6,48,6,30,12,
12,12,30,6,6,30,18,0,24,0,60,33,18,18,30,12,48,0,12,18,42,6,30,0,24,0,72,6,30,15,30,0,24,6,6,24,12,6,54,0,42,18,6,12,36,18,24,9,24,6,30,6,27,18,12,0,54,0,24,15,18,12,66,12,12,6,33,12,42,3,36,0,12,12,21,21,48,18,24,9,48,0,33,18,18,24,24,0,24,0,21,30,42,12,36,21,30,0,42,6,45,30,12,0,42,6,45,21,30,6,48,12,12,0,9,18,42,0,48,0,24,6,42,12,12,27,18,15,48,12,33,36,12,12,24,0,30,12,24,9,66,6,12,12,24,0,48,6,30,12,36,0,30,0,36,24,18,12,30,9,36,6,6,12,27,6,42,0,30,6,27,9,36,24,24,12,54,3,21,18,42,24,24,0,12,6,18,18,42,12,24,18,0,6,36,18,18,12,18,0,30,0,36,24,3,6,72,9,42,0,24,6,30,24,18,0,24,0,24,12,57,21,6,6,30,9,42,12,33,18,66,0,30,12,30,21,51,6,24,6,18,9,33,18,48,24,24,0,42,0,27,18,18,15,36,0,30,6,36,12,54,12,24,0,30,18,48,9,12,18,36,21,48,0,24,18,33,12,42,0,42,0,9,12,12,27,42,12,12,9,48,12,36,30,24,0,48,0,24,15,24,18,36,12,18,9,24,12,42,12,30,0,12,0,30,12,45,18,18,3,48,12,24,12,24,18,30,0,54,6,12,12,42,6,24,21,36,0,36,6,27,30,12,0,24,0,51,12,24,6,36,6,18,9,21,18,48,6,6,0,24,6,54,18,24,18,18,7,30,6,57,30,12,18,36,0,36,12,18,18,45,15,30,12,24,6,48,0,24,18,48,0,30,0,27,30,21,24,48,6,36,0,21,24,48,12,54,0,6,0,66,12,12,6,6,15,72,6,30,36,12,6,6,0,30,12,18,12,45,18,42,12,30,6,30,6,30,18,18,0,72,0,18,18,24,21,42,0,24,6,18,30,24,6,36,0,24,0,54,3,42,36,12,12,24,0,24,12,18,0,48,0,18,0,18,18,42,9,48,18,12,15,39,12,36,24,18,0,42,0,24,27,24,6,30,18,42,6,18,0,57,12,30,0,12,6,36,12,18,12,12,6,12,6,42,24,39,27,66,0,24,15,12,24,33,12,30,6,18,0,63,18,27,18,12,0,66,3,42,24,39,18,42,0,30,6,30,0,42,21,36,0,18,18,6,15,33,18,30,18,54,3,30,24,12,18,72,0,30,0,30,12,39,6,24,18,18,12,24,6,54,27,18,0,48,6,45,6,18,6,42,12,18,0,24,18,30,12,42,0,30,3,48,6,33,21,24,3,48,6,36,30,9,12,48,0,30,18,12,18,18,24,6,12,24,6,36,6,33,12,24,0,42,0,3,30,33,18,48,0,54,6,24,12,24,6,24,0,24,3,78,6,18,18,12,6,36,0,36,18,30,24,18,0,12,6,27,15,48,6,54,21,18,0,27,6,51,15,36,0,30,6,33,24,24,18,42,12,24,0,21,24,57,12,30,0,36,3,36,15,36,21,24,24,36,12,39,18,18,6,42,0,36,18,6,18,42,12,30,3,42,0,27,18,15,18,48,0,54,0,30,33,12,12,30,12,30,6,18,18,48,9,36,0,12,6,54,6,54,12,30,15,30,3,36,36,24,18,24,0,24,6,15,6,24,6,60,12,30,6,66,12,12,18,18,0,48,9,30,12,33,12,30,6,24,0,27,18,36,12,24,0,18,6,36,6,30,24,12,9,60,6,24,24,12,24,54,0,48,0,15,30,30,6,12,18,6,7,36,12,36,18,30,0,60,0,42,3,18,18,36,12,36,6,18,24,78,12,30,0,30,12,27,12,18,42,24,0,54,0,30,12,30,12,36,0,48,3,30,12,42,24,18,24,12,9,66,6,24,18,24,0,24,6,63,18,6,12,84,0,48,12,18,18,18,12,18,0,18,0,54,15,42,24,6,6,54,6,18,30,36,27,24,0,12,6,18,9,48,0,60,6,12,0,36,6,36,30,6,0,66,6,18,24,21,15,54,9,30,24,18,12,18,6,30,0,30,6,48,0,24,18,12,18,30,0,45,6,18,12,48,0,12,0,12,30,60,12,24,12,24,12,24,6,36,30,12,0,36,0,27,27,27,24,54,3,36,0,39,12,54,6,24,0,12,0,54,12,42,18,36,21,36,0,6,30,12,9,36,0,54,12,24,3,60,12,42,15,24,12,42,24,24,24,36,0,36,0,48,24,21,12,30,6,36,18,21,12,48,6,30,0,24,6,36,27,54,0,12,6,48,0,42,24,12,24,78,0,24,3,24,27,30,12,24,21,30,0,30,12,30,24,18,0,30,6,27,30,18,24,54,12,18,6,27,12,57,6,36,0,12,0,30,6,18,24,18,6,42,0,75,30,42,6,30,0,36,6,12,24,36,12,12,9,18,0,30,12,42,12,30,0,36,6,12,12,24,6,42,6,30,21,21,24,39,15,48,0,30,3,78,15,24,24,6,9,24,6,24,12,39,30,42,0,36,3,27,21,36,12,36,24,12,12,60,12,24,21,18,0,66,9,24,18,9,12,48,6,36,0,30,18,24,6,30,0,36,6,39,12,57,36,42,6,36,6,42,6,18,27,42,0,12,12,18,15,66,12,30,15,30,0,18,18,42,18,36,0,24,3,30,24,12,12,30,6,66,6,30,0,51,12,18,0,30,12,45,12,30,18,12,9,30,0,33,30,12,0,42,0,24,0,48,12,45,18,30,12,24,6,39,12,21,30,6,0,42,3,36,18,24,30,18,6,18,18,36,12,24,6,60,0,12,6,30,12,24,6,18,7,66,0,33,18,18,21,72,0,36,6,27,24,42,6,30,12,18,0,78,18,33,30,18,0,30,6,48,24,18,6,36,6,30,12,12,30,66,6,24,0,36,12,24,0,36,18,24,18,78,0,42,30,21,24,18,0,48,0,18,9,42,6,54,18,12,0,36,18,12,36,36,0,30,12,18,27,36,12,66,6,42,0,12,18,48,18,24,0,24,0,66,15,30,18,18,24,54,0,33,12,18,6,36,0,12,15,24,18,48,6,36,18,18,6,36,6,66,0,24,0,30,6,12,36,9,24,48,6,18,12,18,12,42,18,36,0,30,6,42,6,60,24,6,6,24,0,39,24,6,6,60,0,30,0,30,24,45,3,12,6,18,15,48,0,18,24,30,0,60,12,36,27,24,24,60,18,36,3,12,6,54,12,30,0,12,3,39,12,60,27,36,12,24,6,24,30,33,18,48,0,42,6,30,6,6,12,30,18,24,0,66,6,27,36,12,0,66,0,18,6,24,33,30,3,42,18,30,30,66,3,36,0,24,6,6,18,30,18,48,6,48,3,30,12,12,18,54,0,42,6,15,18,30,18,12,6,42,6,60,12,36,24,0,0,36,12,60,24,24,12,54,6,42,0,12,6,51,18,54,0,6,0,30,0,12,12,24,15,42,3,42,24,24,30,54,0,12,0,24,12,69,18,12,18,18,9,39,12,36,12,18,0,48,0,33,27,54,3,24,3,30,18,21,24,30,15,42,0,12,12,63,18,15,30,18,18,60,0,18,12,36,24,54,0,36,0,24,9,48,6,60,18,30,6,27,18,36,6,30,0,54,6,18,30,27,6,42,6,60,6,39,30,18,12,30,0,12,3,42,9,42,33,42,6,24,6,48,24,6,12,30,0,30,6,27,15,66,6,42,21,30,0,42,12,18,18,36,0,60,0,39,30,12,24,30,6,24,9,24,18,66,12,18,0,18,6,57,12,30,12,36,18,18,6,9,36,21,12,30,0,60,6,12,24,18,12,42,15,42,6,24,12,36,18,12,0,42,0,36,12,21,12,30,6,18,0,30,12,66,12,36,0,24,1,60,21,51,18,6,12,60,6,12,18,12,36,48,0,30,9,27,12,18,6,36,18,30,3,66,6,24,30,18,0,48,6,42,18,18,15,72,6,42,12,18,24,36,6,24,0,18,12,51,9,36,42,24,6,30,0,30,36,18,6,36,0,48,6,30,21,48,9,24,6,6,12,60,12,48,15,42,0,42,12,24,18,18,24,42,6,30,12,6,6,69,12,48,0,18,0,48,6,18,30,24,15,66,6,42,6,21,18,18,0,36,18,24,24,42,18,48,24,0,0,33,12,36,18,30,0,54,0,48,24,30,12,72,0,12,6,18,6,39,18,6,0,30,6,24,6,48,18,18,18,48,0,15,18,18,30,72,0,18,6,12,15,72,9,36,9,12,12,45,18,45,24,24,0,36,6,45,30,18,18,30,6,66,0,18,18,36,12,36,0,30,6,48,9,30,24,24,12,36,6,27,36,24,0,54,0,42,12,18,24,30,12,54,12,18,3,75,12,36,24,24,0,42,0,24,24,30,24,36,12,12,12,42,6,48,0,42,0,6,0,48,18,27,18,24,15,72,0,33,24,24,30,30,0,18,6,21,24,60,6,24,15,42,6,36,12,36,18,12,0,42,9,48,12,30,12,42,6,30,6,21,30,48,0,30,0,42,6,30,12,30,24,18,6,18,0,45,30,9,12,54,0,54,12,30,12,30,18,18,18,18,0,54,0,30,18,24,0,24,0,18,30,15,21,30,24,42,6,18,18,45,18,42,0,30,18,57,18,27,12,30,0,72,9,48,12,42,12,42,0,24,0,36,0,30,3,42,24,12,12,36,12,51,42,24,0,60,0,9,24,18,24,60,3,48,0,24,24,42,18,36,0,24,0,30,15,36,30,24,12,18,18,27,24,48,6,60,0,54,6}

int main()
{
    int cnt=0,n;
    scanf("%d",&n);
    for(int a=1;a<=n;++a) {
        printf("%d\n",ans[a]);
    }
}

Compiler output:
a.cc:13:1: error: expected ',' or ';' before 'int'
   13 | int main()
      | ^~~