#include <bits/stdc++.h>

using namespace std;
typedef long long ll;
const int Mod = 998244353;
const int N = 200005;
int n;
int f[N];
int s[2];

int Qpow(int x,int y) {
	int rtn = 1;
	while(y) {
		if(y&1) rtn = 1LL * rtn * x % Mod;
		x = 1LL * x * x % Mod; y >>= 1;
	}
	return rtn;
}

int main() {
	cin>>n;
	f[0] = f[1] = 1; s[0] = s[1] = 1;
	for(int i=2;i<=n;i++) {
		int x = i&1;
		f[i] = s[x^1];
		s[x] = (s[x] + f[i]) % Mod;
	}
	ll ans = Qpow(2, n);
	ans = 1LL * f[n] * Qpow(ans, Mod-2) % Mod;
	printf("%lld\n",ans);
	return 0;
}
