# include # include # include # include # include # include # include # include # include # include # include # include # include # include # include #include #include #include #include #include typedef long long int ll; const int INF = 1 << 30; using namespace std; const int MOD = 100000; #define pp pair #define FOR(i,a,n) for(int i=(ll)a;i<(ll)n;++i) #define TFOR(i,n)FOR(i,0,n) #define ALL(x) x.begin(),x.end(); int main() { ll n; cin >> n; ll ans=0; ll bo = 1, ci = 1; for (ll i = 1; i <= (n+1) / 2;++i) { bo *= i; ci *= (n - i-1); if (ci%bo == 0 && (ci / bo) % 2 == 0)ans += 2; } cout << ans << endl; return 0; }