#include <iostream>
#include <cstdio>
#include <string>
#include <string.h>
#include <queue>
#include <math.h>
#include <cmath>
#include <map>
#include <set>
#include <vector>
#include <algorithm>
#include <bitset>
#include <list>
#include <ctype.h>
#include <cassert>
#include <stack>
#include <fstream>
#include <unordered_map>
#include <unordered_set>
#include <ctime>
#include <functional>
#include <ctime>
#include <limits>
#include <tuple>
#include <complex>
#include <numeric>

using namespace std;

#define snd second
#define fst first
#define mp make_pair
#define ll long long
#define ull unsigned long long
#define ld long double
#define pb push_back
#define left _left
#define right _right

const ld pi = acos(-1.0l);

template<typename T>
T abs(T x) {
    return x > 0 ? x : -x;
}

template<typename T>
T sqr(T x) {
    return x * x;
}

template<typename T>
bool chmin(T &x, T y) {
    if (x > y) {
        x = y;
        return true;
    }
    return false;
}

template<typename T>
bool chmax(T &x, T y) {
    if (x < y) {
        x = y;
        return true;
    }
    return false;
}

template<typename U, typename V>
ostream &operator<<(ostream &s, const pair<U, V> &x) {
    s << "(" << x.fst << ", " << x.snd << ")";
    return s;
}

template<typename U>
ostream &operator<<(ostream &s, const vector<U> &x) {
    s << "[";
    bool was = false;
    for (auto it : x) {
        if (was) {
            s << ", ";
        }
        was = true;
        s << it;
    }
    s << "]";
    return s;
}

template<typename U>
ostream &operator<<(ostream &s, const set<U> &x) {
    s << "{";
    bool was = false;
    for (auto it : x) {
        if (was) {
            s << ", ";
        }
        was = true;
        s << it;
    }
    s << "}";
    return s;
}

template<int sz>
ostream operator<<(ostream &s, const bitset<sz> &x) {
    for (int i = 0; i < sz; i++) {
        s << x[i];
    }
    return s;
}


//-----------------------------------------------------------------------------

const ll mod = 924844033;
const int maxn = 2005;
ll f[maxn], fi[maxn];
ll dp[maxn][maxn][3];

ll bpow(ll x, ll n) {
    ll res = 1;
    while (n) {
        if (n & 1) {
            res = res * x % mod;
        }
        x = x * x % mod;
        n >>= 1;
    }
    return res;
}

ll dp2[maxn], ndp2[maxn];

int main() {
    srand(time(NULL));

    retry:
#ifdef LOCAL
    // gen();

    freopen("a.in", "r", stdin);
    //freopen("a.out", "w", stdout);
#else
    //freopen(".in", "r", stdin);
    //freopen(".out", "w", stdout);
#endif

    int n, k;
    cin >> n >> k;

    f[0] = fi[0] = 1;
    for (int i = 1; i < maxn; i++) {
        f[i] = f[i - 1] * i % mod;
        fi[i] = bpow(f[i], mod - 2);
    }

    dp[0][0][0] = 1;

    for (int i = 1; i < maxn; i++) {
       for (int j = 0; j < maxn; j++) {
           dp[i][j][0] += dp[i - 1][j][0] + dp[i - 1][j][1] * 2LL;
           dp[i][j][0] %= mod;

           if (i > 1 && j > 0) {
               dp[i][j][1] += (dp[i - 2][j - 1][0] + dp[i - 2][j - 1][1] * 2LL) + dp[i - 1][j - 1][1];
               dp[i][j][1] %= mod;

               if (j > 1) {
                   dp[i][j][0] += dp[i - 2][j - 2][0] + dp[i - 2][j - 2][1] * 2LL;
                   dp[i][j][0] %= mod;
               }
           }
       }
    }


    //cout << dp[2][1][1] << endl;

    dp2[0] = 1;

    for (int i = 0; i < k; i++) {
        int cnt = (n - i - 1) / k + 1;

        fill(ndp2, ndp2 + maxn, 0);

        for (int j = 0; j <= cnt; j++) {
            for (int h = 0; h + j < maxn; h++) {
                ndp2[h + j] += dp2[h] * (dp[cnt][j][0] + dp[cnt][j][1] * 2LL) % mod;
                ndp2[h + j] %= mod;
            }
        }

        for (int j = 0; j < maxn; j++) {
            dp2[j] = ndp2[j];
        }
    }

    ll ans = 0;
    for (int i = 0; i <= n; i++) {
        //cout << dp2[i] << endl;
        if (i & 1) {
            ans -= dp2[i] * f[n - i] % mod;
            ans %= mod;
            ans += mod;
            ans %= mod;
        } else {
            ans += dp2[i] * f[n - i] % mod;
            ans %= mod;
        }
    }



    cout << ans << endl;



    return 0;
}

Measured memory_bytes: 94464