#include<bits/stdc++.h>
using namespace std;
#define ll long long
const ll p=1000000007ll;
const int N=55;
ll dp[N][N][N*N],tmp;
inline void upd(ll &a,int b){a=(a+b*tmp)%p;}
int main(){
	int n,m,i,j,k;
	scanf("%d%d",&n,&m);
	if(m&1){printf("0");return 0;}
	dp[0][0][0]=1ll;
	for(i=1;i<=n;++i)for(j=0;j<i;++j)for(k=0;k<=i*i;++k)if(tmp=dp[i-1][j][k]){
		upd(dp[i][j  ][k       ],1);
		upd(dp[i][j+1][k+ i    ],((i-j)<<1)-1);
		upd(dp[i][j+2][k+(i<<1)], (i-j-1)*(i-j-1));
	}
	printf("%lld",dp[n][n][(n*(n+1)+m)>>1]);
	return 0;
}