#include <stdio.h>  
#include <algorithm>  
#include <assert.h>
#include <bitset>
#include <cmath>  
#include <complex>  
#include <deque>  
#include <functional>  
#include <iostream>  
#include <limits.h>  
#include <map>  
#include <math.h>  
#include <queue>  
#include <set>  
#include <stdlib.h>  
#include <string.h>  
#include <string>  
#include <time.h>  
#include <unordered_map>  
#include <unordered_set>  
#include <vector>  
#include <chrono>
#include <random>
#include <time.h>
#include <fstream>
#define ll long long
#define rep2(i,a,b) for(ll i=a;i<=b;++i)
#define rep(i,n) for(ll i=0;i<n;i++)
#define rep3(i,a,b) for(ll i=a;i>=b;i--)
#define pii pair<int,int>
#define pll pair<ll,ll>
#define pq priority_queue<int>
#define pqg priority_queue<int,vector<int>,greater<int>>
#define pb push_back
#define vec vector<int>
#define vecll vector<ll>
#define vecpii vector<pii>
#define endl "\n"
#define all(c) begin(c),end(c)
using namespace std;
int in() {int x;scanf("%d",&x);return x;}
ll lin() {ll x;scanf("%lld",&x);return x;}

#define INF 1e9+7
#define LLINF 1e18+7
#define N 250000
ll MOD=1e9+7;

template <std::uint_fast64_t Modulus> class modint {
  using u64 = std::uint_fast64_t;

public:
  u64 a;

  constexpr modint(const u64 x = 0) noexcept : a(x % Modulus) {}
  constexpr u64 &value() noexcept { return a; }
  constexpr const u64 &value() const noexcept { return a; }
  constexpr modint operator+(const modint rhs) const noexcept {
    return modint(*this) += rhs;
  }
  constexpr modint operator-(const modint rhs) const noexcept {
    return modint(*this) -= rhs;
  }
  constexpr modint operator*(const modint rhs) const noexcept {
    return modint(*this) *= rhs;
  }
  constexpr modint operator/(const modint rhs) const noexcept {
    return modint(*this) /= rhs;
  }
  constexpr modint &operator+=(const modint rhs) noexcept {
    a += rhs.a;
    if (a >= Modulus) {
      a -= Modulus;
    }
    return *this;
  }
  constexpr modint &operator-=(const modint rhs) noexcept {
    if (a < rhs.a) {
      a += Modulus;
    }
    a -= rhs.a;
    return *this;
  }
  constexpr modint &operator*=(const modint rhs) noexcept {
    a = a * rhs.a % Modulus;
    return *this;
  }
  constexpr modint &operator/=(modint rhs) noexcept {
    u64 exp = Modulus - 2;
    while (exp) {
      if (exp % 2) {
        *this *= rhs;
      }
      rhs *= rhs;
      exp /= 2;
    }
    return *this;
  }
};

using mint = modint<1000000007>;

mint dp[2][5000][51][51];

//vector<vector<vector<ll> > > dp(5000,vector<vector<mint> >(51,vector<mint> (50)));
main(){
    ll n=in();
    ll k=in();
    if(k%2){
        cout<<0;return 0;
    }
    ll s=(k+n*(n+1))/2;
    dp[0][0][0][0]=1;
    int M=0,T=0;
    rep2(i,1,n){
        rep2(j,0,M)rep2(c,0,T)rep2(d,0,T)dp[i%2][j][c][d]=0;
        //vector<vector<vector<mint> > > dp[i%2](5000,vector<vector<mint> >(51,vector<mint> (50)));
        rep2(j,0,M){
            rep2(c,0,T){
                rep2(dd,0,T/2){
                    int d=dd*2+c%2;
                    mint now=dp[(i+1)%2][j][c][d];
                    if(c>=1&&d>=1){
                        dp[i%2][j+i*2][c-1][d-1]+=now*c*d;
                    }
                    if(d>=1){
                        dp[i%2][j+i][c][d]+=now*d;
                    }
                    if(c>=1){
                        dp[i%2][j+i][c][d]+=now*c;
                    }
                    dp[i%2][j+i][c][d]+=now;
                    dp[i%2][j][c+1][d+1]+=now;
                }
            }
        }
        T+=1;
        M+=i*2;
    }
    cout<<dp[n%2][s][0][0].a<<endl;
}



Measured memory_bytes: 104704