            #include <bits/stdc++.h>
            #include <ext/pb_ds/assoc_container.hpp>
            #include <ext/pb_ds/tree_policy.hpp>
            using namespace std;
            using namespace __gnu_pbds;
            #define rep(i, a , b) for (ll i =a ; i < b ; i++)
            #define IOS ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
            #define endl "\n"
            #define pb push_back
            #define F first
            #define S second
            #define print(a)       for(auto x : a) cout << x << " "; cout << endl
            #define print1(a)      for(auto x : a) cout << x.F << " " << x.S << endl
            #define print2(a,x,y)  for(int i = x; i < y; i++) cout<< a[i]<< " "; cout << endl
            typedef long long  int ll;
            const ll N =  3e3+5;
            const ll mod = 998244353;
            const ll inf = 1e18;
            ll   n  , k  , m , q  , w , u , x , y , v , z , dp[N][N] ;

    ll pow_mod_m(ll a , ll n)
    {
        if(!n)
            return 1;
        ll pt =  pow_mod_m(a,n/2);
        pt *= pt , pt %= mod;
        if(n&1)
            pt *= a  ,pt %= mod;
        return pt;
    }


    int solve( int n , int k )
    {
        if( n < k )
        {
            return 0;
        }
        if( k == 0 )
        {
            return (n == 0);
        }
        ll &ans = dp[n][k];
        if(ans != -1)
        {
            return ans;
        }
        ans = solve(n-1,k-1) + solve( n , 2*k );
        if( ans >= mod ) ans -= mod;
        return ans;
    }


    int main()
    {
         IOS;
         int ts =1;
         ///cin >> ts ;
         while(ts--)
         {
             cin >> n >> k;
             memset(dp , -1, sizeof(dp));
             cout << solve(n ,k ) << endl;
         }
    }

// #pragma GCC optimize("Ofast,unroll-loops")
// #pragma GCC target("avx,avx2,fma")

#include <bits/stdc++.h>
using namespace std;

#define ll long long
#define ull unsigned long long
#define dd double
#define ld long double
#define sl(n) scanf("%lld", &n)
#define si(n) scanf("%d", &n)
#define sd(n) scanf("%lf", &n)
#define pll pair <ll, ll>
#define pii pair <int, int>
#define mp make_pair
#define pb push_back
#define all(v) v.begin(), v.end()
#define inf (1LL << 61)
#define loop(i, start, stop, inc) for(ll i = start; i <= stop; i += inc)
#define for1(i, stop) for(ll i = 1; i <= stop; ++i)
#define for0(i, stop) for(ll i = 0; i < stop; ++i)
#define rep1(i, start) for(ll i = start; i >= 1; --i)
#define rep0(i, start) for(ll i = (start-1); i >= 0; --i)
#define ms(n, i) memset(n, i, sizeof(n))
#define casep(n) printf("Case %lld:", ++n)
#define pn printf("\n")
#define pf printf
#define EL '\n'
#define fastio std::ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);

int main()
{
    ll n;
    cin >> n;

    ll lcm = 1;

    for1(i, n) {
        ll mul = lcm * i;
        ll g = __gcd(lcm, i);

        lcm = mul / g;
    }

    cout << lcm + 1 << EL;

    return 0;
}
