//~ while (clock()<=69*CLOCKS_PER_SEC)
//~ #pragma comment(linker, "/stack:200000000")
//~ #pragma GCC optimize("O3")
//~ #pragma GCC optimize("Ofast")
//~ #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
//~ #pragma GCC optimize("unroll-loops")
#include<bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>

#define pb push_back
#define SZ(x) ((int)(x).size())
#define ALL(x) x.begin(),x.end()
#define all(x) x.begin(),x.end()
#define fi first
#define se second
#define _upgrade ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0);
#define erase_duplicates(x) sort(all(x)); (x).resize(distance((x).begin(), unique(all(x))));


using namespace std;
using namespace __gnu_pbds;
template<typename T>
using ordered_set = tree<
T,
null_type,
less<T>,
rb_tree_tag,
tree_order_statistics_node_update>;

//X.find_by_order(k); - zwraca iterator na k-ty element (numeracja od zerowego)
//X.order_of_key(k); - zwraca liczbę elementów ostro mniejszych niż k

typedef long long LL;
typedef pair<int,int> PII;
typedef pair<LL,LL> PLL;
typedef vector<PII> VPII;
typedef vector<PLL> VPLL;
typedef vector<LL> VLL;
typedef vector<int> VI;
typedef vector<string> VS;
typedef vector<char> VC;
typedef long double LD;
typedef pair<LD,LD> PLD;
typedef vector<LD> VLD;
typedef vector<PLD> VPLD;

template<class TH> void _dbg(const char *sdbg, TH h){ cerr<<sdbg<<" = "<<h<<endl; }
template<class TH, class... TA> void _dbg(const char *sdbg, TH h, TA... a) {
  while(*sdbg!=',')cerr<<*sdbg++;
  cerr<<" = "<<h<<", "; _dbg(sdbg+1, a...);
}

#ifdef LOCAL
#define dbg(...) _dbg(#__VA_ARGS__, __VA_ARGS__)
#else
#define dbg(...)
#define cerr if(0)cout
#endif

const int maxn = (3e3)+7;
const int maxk = 20;
const int inf = (1e9)+7;
const LL LLinf = ((LL)1e18)+7LL;
const LD eps = 1e-9;
const LL mod = 998244353LL;

// ***************************** CODE ***************************** //

LL dp[maxn];
LL poch[maxn];
LL stala[maxn];
LL net[maxn][maxn];

int main()
{
	_upgrade
  int n, x;
  cin>>n>>x;
  net[0][0] = 1;
  dp[0] = 1;
  for(int i = 1;i <= n;i++)
    for(int j = 0;j <= i;j++)
      net[i][j] = ((j == 0 ? 0 : net[i - 1][j - 1]) + net[i - 1][j]) % mod;
  if(x & 1)
  {
    for(int i = 1;i <= n;i++)
      dp[i]++;
    for(int i = 0;i <= n;i++)
      for(int j = 0;j <= n;j++)
        if(i + j + 1 <= n && (2 * i + 2 * j + 1 < x))
          dp[i + j + 1]++;
  }
  else
  {
    for(int i = 1;i * 2 < x;i++)
      dp[i]++;
    for(int i = 0;i <= n;i++)
      for(int j = 0;j <= n;j++)
        if(i + j + 1 <= n && 2 * i < x && 2 * j < x)
          dp[i + j + 1]++;
  }
   LL res = 0LL;
    // for(int i = 0;i <= n;i++)
    // {
    //   res = (res + net[n][i] * dp[n - i]) % mod;
    // }
    // res %= mod;
    // res += mod;
    // res %= mod;
    // cout<<res<<endl;
  for(int dl = 0;dl <= n - 2;dl++)
    for(int dwa = 0;dwa <= dl;dwa++)
    {
      int jed = dl - dwa;
      int suma = jed + dwa * 2 + 2;
      if(suma >= x) continue;
      if(suma % 2 == x % 2)
      {
        int dodaj = (x - suma - 1) / 2;
        assert(dodaj >= 0);

        poch[dl + 2] += net[dl][dwa];
        poch[dl + 2] %= mod;
        if(dl + 2 + dodaj + 1 <= n)
        {
          poch[dl + 2 + dodaj + 1] -= net[dl][dwa];
          stala[dl + 2 + dodaj + 1] -= (dodaj + 1) * net[dl][dwa] % mod;
          stala[dl + 2 + dodaj + 1] %= mod;
          poch[dl + 2 + dodaj + 1] %= mod;
        }
        // dbg(dl + 2, dodaj, net[dl][dwa]);
      }
      else
      {
        int dodaj = (x - suma - 1) / 2;
        assert(dodaj >= 0);
        // dbg(dl + 2, net[dl][dwa], dodaj);
        poch[dl + 2] += net[dl][dwa];
        poch[dl + 2] %= mod;
        if(dl + 2 + dodaj + 1 <= n)
        {
          poch[dl + 2 + dodaj + 1] -= 2 * net[dl][dwa];
          poch[dl + 2 + dodaj + 1] %= mod;
        }
        if(dl + 2 + 2 * dodaj + 1 <= n)
        {
          poch[dl + 2 + 2 * dodaj + 1] += net[dl][dwa];
          stala[dl + 2 + 2 * dodaj + 1] -= net[dl][dwa];
          poch[dl + 2 + 2 * dodaj + 1] %= mod;
          stala[dl + 2 + 2 * dodaj + 1] %= mod;
        }
      }
    }
  LL curpoch = 0;
  LL cursuma = 0;
  for(int i = 0;i <= n;i++)
  {
    curpoch += poch[i];
    cursuma += stala[i] + curpoch;
    curpoch %= mod;
    cursuma %= mod;
    // dbg(poch[i], stala[i], i, cursuma, curpoch);
    dp[i] += cursuma;
    dp[i] %= mod;
  }
  res = 0LL;
  for(int i = 0;i <= n;i++)
  {
    res = (res + net[n][i] * dp[n - i]) % mod;
  }
  res %= mod;
  res += mod;
  res %= mod;
  cout<<res;
	return 0;
}


Measured memory_bytes: 69120