#include <bits/stdc++.h>
using namespace std;
const int mod = 998244353;
int n, k;
int memo[1001][2001][4];
int dp(int pos, int com, int col) {
  if (com < 0) return 0;
  if (pos == 0) return com == 0;
  int &ret = memo[pos][com][col];
  if (ret != -1) return ret;
  ret = 0;
  for (int i = 0; i < 4; i++) {
    int temp = 0;
    temp += (i & 1) != ((i & 2) >> 1);
    temp += (col & 1) != (i & 1);
    temp += (col & 2) != (i & 2);
    if (temp == 1)
      temp = 0;
    else if (temp == 2)
      temp = 1;
    else if (temp == 3)
      temp = 2;
    ret += dp(pos - 1, com - temp, i);
    ret %= mod;
  }
  return ret;
}
int main() {
  cin >> n >> k;
  memset(memo, -1, 4 * 4 * 1001 * 2001);
  int ans = 0;
  for (int i = 0; i < 4; i++) {
    int temp;
    if (i == 0 || i == 3)
      temp = 1;
    else
      temp = 2;
    ans += dp(n - 1, k - temp, i);
    ans %= mod;
  }
  cout << ans;
  cin >> n;
}

### Prompt

Develop a solution in CPP to the problem described below:

You are given a grid, consisting of 2 rows and n columns. Each cell of this grid should be colored either black or white.

Two cells are considered neighbours if they have a common border and share the same color. Two cells A and B belong to the same component if they are neighbours, or if there is a neighbour of A that belongs to the same component with B.

Let's call some bicoloring beautiful if it has exactly k components.

Count the number of beautiful bicolorings. The number can be big enough, so print the answer modulo 998244353.

Input

The only line contains two integers n and k (1 ≤ n ≤ 1000, 1 ≤ k ≤ 2n) — the number of columns in a grid and the number of components required.

Output

Print a single integer — the number of beautiful bicolorings modulo 998244353.

Examples

Input

3 4


Output

12


Input

4 1


Output

2


Input

1 2


Output

2

Note

One of possible bicolorings in sample 1:

<image>

### Response

```cpp
#include <bits/stdc++.h>
using namespace std;
const int mod = 998244353;
int n, k;
int memo[1001][2001][4];
int dp(int pos, int com, int col) {
  if (com < 0) return 0;
  if (pos == 0) return com == 0;
  int &ret = memo[pos][com][col];
  if (ret != -1) return ret;
  ret = 0;
  for (int i = 0; i < 4; i++) {
    int temp = 0;
    temp += (i & 1) != ((i & 2) >> 1);
    temp += (col & 1) != (i & 1);
    temp += (col & 2) != (i & 2);
    if (temp == 1)
      temp = 0;
    else if (temp == 2)
      temp = 1;
    else if (temp == 3)
      temp = 2;
    ret += dp(pos - 1, com - temp, i);
    ret %= mod;
  }
  return ret;
}
int main() {
  cin >> n >> k;
  memset(memo, -1, 4 * 4 * 1001 * 2001);
  int ans = 0;
  for (int i = 0; i < 4; i++) {
    int temp;
    if (i == 0 || i == 3)
      temp = 1;
    else
      temp = 2;
    ans += dp(n - 1, k - temp, i);
    ans %= mod;
  }
  cout << ans;
  cin >> n;
}

```