#include #include using namespace std; typedef long long ll; const ll mod = 998244353; ll modpow(ll a, ll b, ll p = mod){ if(b == 0) return 1; if(b % 2 == 0){ ll d = modpow(a, b/2, p); return (d*d) % p; }else{ return (a%p * modpow(a, b-1, p)) % p; } } struct ModComb{ vector po, inv; ll N; ModComb(ll n) : N(n), po(n), inv(n) { po[0] = 1; for(int i = 1; i < N; i++) po[i] = (po[i-1] * i) % mod; inv[N-1] = modpow(po[N-1], mod-2, mod); for(int i = N-2; i >= 0; i--) inv[i] = (inv[i+1] * (i+1)) % mod; } ll nCk(ll n, ll k){ if(k == 0) return 1; if(n < k) return 0; return (((po[n]*inv[n-k])%mod)*inv[k])%mod; } ll nPk(ll n, ll k){ if(k == 0) return 1; if(n < k) return 0; return (po[n]*inv[n-k])%mod; } ll nHk(ll n, ll k){ if(n == 0 && k == 0) return 1; return nCk(n+k-1, k-1); } }; int main(){ int n; cin >> n; ll ans = modpow(2,n,mod)*2%mod; ModComb mc(n+1); for(int i = 2; i < n; i += 2){ ans += mc.nCk(n, i)*modpow(2,abs(n-2*i),mod)%mod*2%mod; ans %= mod; } cout << ans << endl; return 0; }