#include using namespace std; #define rep(i,n) for(int i = 0; i < (int)n; i++) using ll = long long; const int MAX = 200000; const ll mod = 998244353; ll Pow(ll x, ll n){ if(n == 0) return 1; return (n % 2 == 0 ? Pow(x*x % mod,n/2) : x * Pow(x,n-1) % mod); } ll fac[MAX], finv[MAX], inv[MAX]; void COMinit() { fac[0] = fac[1] = 1; finv[0] = finv[1] = 1; inv[1] = 1; for (int i = 2; i < MAX; i++){ fac[i] = fac[i-1] * (ll)i % mod; inv[i] = mod - inv[mod%i] * (mod/(ll)i) % mod; finv[i] = finv[i-1] * inv[i] % mod; } } ll COM(int n, int k){ if (n < k) return 0; if (n < 0 || k < 0) return 0; return fac[n] * (finv[k] * finv[n-k] % mod) % mod; } int main(){ int n; cin >> n; COMinit(); ll ans = 0; for(int j = -n; j <= n; j++) { if((j+n) % 2 or (n-j)/2 % 2) continue; int y = (n-j)/2; (ans += 2*(Pow(2,abs(j))*COM(n,y)%mod)) %= mod; } cout << ans << endl; return 0; }