#include <bits/stdc++.h>
using namespace std;
const int N = 2010, mod = 924844033;
long long dp[N][N][3], fact[N], p[N], n, K;
int main() {
  ios::sync_with_stdio(false), cin.tie(0), cout.tie(0);
  cin >> n >> K;
  fact[0] = 1;
  for (int i = 1; i < N; i++) fact[i] = 1LL * fact[i - 1] * i % mod;
  int last = 1;
  for (int i = 1; i <= K * 2; i++)
    for (int j = i; j <= n; j += K * 2) p[last++] = j;
  dp[0][0][0] = 1;
  for (int i = 1; i <= n; i++) {
    dp[i][0][0] = 1;
    for (int j = 1; j <= i; j++) {
      dp[i][j][0] = (dp[i - 1][j][0] + dp[i - 1][j][1] + dp[i - 1][j][2]) % mod;
      if (p[i] - K >= 1) {
        dp[i][j][1] = (dp[i - 1][j - 1][0] + dp[i - 1][j - 1][1]) % mod;
        if (p[i] - K != p[i - 1] + K)
          (dp[i][j][1] += dp[i - 1][j - 1][2]) %= mod;
      }
      if (p[i] + K <= n) {
        dp[i][j][2] = (dp[i - 1][j - 1][0] + dp[i - 1][j - 1][2]) % mod;
        if (p[i] + K != p[i - 1] - K)
          (dp[i][j][2] += dp[i - 1][j - 1][1]) %= mod;
      }
    }
  }
  long long ans = 0;
  for (int i = 1; i <= n; i++) {
    int x = (dp[n][i][0] + dp[n][i][1] + dp[n][i][2]) % mod;
    if (i & 1)
      (ans += 1LL * (x)*fact[n - i] % mod) %= mod;
    else {
      ans = ((ans - (1LL * x * fact[n - i]) % mod) % mod + mod) % mod;
    }
  }
  cout << ((fact[n] - ans) % mod + mod) % mod << '\n';
  return 0;
}
