#include<bits/stdc++.h>
using namespace std;
#define debug printf("%d %s\n",__LINE__,__FUNCTION__)
using ll=long long;using ld=double;using pii=pair<int,int>;using vi=vector<int>;
using qi=queue<int>;using pqi=priority_queue<int>;using si=set<int>;
#define pb push_back
#define mk make_pair
#define ins insert
#define era erase
#define fi first
#define se second
#define lowbit(x) x&-x
const int INF=0x3f3f3f3f;
const ll INFLL=0x3f3f3f3f3f3f3f3f;
const double PI=acos(-1.0);
int _w,_t;FILE* _f;
// #define MULTI_CASES

const int MOD=998244353,P=499122177,N=2e5+5;

int ans[N];

int plu(int u,int v){
    return (u+v)%MOD;
}

int mul(int u,int v){
    return (int)(1LL*u*v%MOD);
}

int qpow(int u,int v){
    int tmp=1;
    while(v>0){
        if(v&1){
            tmp=mul(tmp,u);
        }
        u=mul(u,u);
        v>>=1;
    }
    return tmp;
}

int n;

void solve(){
    ans[1]=ans[2]=1;ans[3]=2;
    _w=scanf("%d",&n);
    for(int i=4;i<=n;i++){
        ans[i]=plu(ans[i-2],ans[i-1]);
    }
    printf("%d\n",mul(ans[n],qpow(P,n)));
}

int main(){
    #ifdef MULTI_CASES
    _w=scanf("%d",&_t);while(_t--)
    #endif
    solve();
    return 0;
}