#include #include #include #include #include #include #include #include using namespace std; typedef long long LL; const double pi=acos(-1.0); int n; LL dp[40][40]; LL calc(LL n,int m) { LL ans=1; LL tmp=n+m-1; for(int i=1;i<=m;i++) { ans*=tmp; ans/=i; tmp--; } return ans; } LL dfs(int n,int mx) { if(n=0;j--) { ans2+=dfs(n-i*mx,j); } ans+=ans1*ans2; } return ans; } int main() { memset(dp,-1,sizeof dp); while(scanf("%d",&n)==1) { LL ans=0; for(int i=n-1;i>=0;i--) { ans+=dfs(n-1,i); } printf("%I64d\n",ans); } return 0; }