#include #include // #include // #include using namespace std; using namespace atcoder; // using namespace __gnu_pbds; using ll=long long; #define int ll using ld = long double; #define _overload3(_1,_2,_3,name,...) name #define _rep(i,n) repi(i,0,n) #define repi(i,a,b) for(int i=int(a);i=int(0);--i) #define fore(i,a) for(auto &i:a) #define all(x) x.begin(),x.end() #define sz(x) ((int)(x).size()) #define bp(x) (__builtin_popcount((long long)(x))) #define pb push_back #define eb emplace_back #define mpa make_pair #define bit(n) (1LL<<(n)) template using V = vector; template using VV = V>; template using max_heap = priority_queue; template using min_heap = priority_queue, greater<>>; #define P pair #define TP tuple #define F first #define S second templatebool chmax(T &a, const T &b) { if (abool chmin(T &a, const T &b) { if (b struct Fp { long long val; constexpr Fp(long long v = 0) noexcept : val(v % MOD) { if (val < 0) val += MOD; } constexpr int getmod() { return MOD; } constexpr Fp operator - () const noexcept { return val ? MOD - val : 0; } constexpr Fp operator + (const Fp& r) const noexcept { return Fp(*this) += r; } constexpr Fp operator - (const Fp& r) const noexcept { return Fp(*this) -= r; } constexpr Fp operator * (const Fp& r) const noexcept { return Fp(*this) *= r; } constexpr Fp operator / (const Fp& r) const noexcept { return Fp(*this) /= r; } constexpr Fp& operator += (const Fp& r) noexcept { val += r.val; if (val >= MOD) val -= MOD; return *this; } constexpr Fp& operator -= (const Fp& r) noexcept { val -= r.val; if (val < 0) val += MOD; return *this; } constexpr Fp& operator *= (const Fp& r) noexcept { val = val * r.val % MOD; return *this; } constexpr Fp& operator /= (const Fp& r) noexcept { long long a = r.val, b = MOD, u = 1, v = 0; while (b) { long long t = a / b; a -= t * b; swap(a, b); u -= t * v; swap(u, v); } val = val * u % MOD; if (val < 0) val += MOD; return *this; } constexpr bool operator == (const Fp& r) const noexcept { return this->val == r.val; } constexpr bool operator != (const Fp& r) const noexcept { return this->val != r.val; } friend constexpr ostream& operator << (ostream &os, const Fp& x) noexcept { return os << x.val; } friend constexpr Fp modpow(const Fp &a, long long n) noexcept { if (n == 0) return 1; auto t = modpow(a, n / 2); t = t * t; if (n & 1) t = t * a; return t; } }; // const int MOD = 1000000007; const int MOD = 998244353; using mint = Fp; // (a**n)%mod // const int MOD = 1000000007; // const int MOD = 998244353; ll modpow(ll a,ll n){ ll res=1; while(n>0){ if(n&1){ res=res*a%MOD; } a=a*a%MOD; n>>=1; } return res; } ll f(int t){ if(t==0)return 1; ll res=1; rep(i,1,t+1)res*=i; return res; } signed main() { ll n;cin>>n; // ll ans=0; // rep(i,n+1){ // rep(j,n+1){ // rep(k,n+1){ // if(i+j+k!=n)continue; // cout<