class Solution{
public:
vector<int> numberOfDice(int n){
vector <int> res;
vector<int> f(n*6+1);
f[0]=1;
for (int i=1;i<=n;i++)
{
for (int j=6*n;j>=1;j--)
{
int sum=0;
for(int k=1;k<=min(j,6);k++)
{
sum+=f[j-k];
f[j]=sum;
}
}
f[0]=0;
}
for(int i = n; i <= n * 6; i ++) res.push_back(f[i]);
return res;
}
};