#include<bits/stdc++.h>
#define ll long long int 
using namespace std;

void solve()
{
  ll n;
  cin>>n;
  if(n%2==0)
  {
    cout<<(n/2+1)*(n/2+1)<<endl;
  }
  else
  {
    cout<<((n+2)*(n+2))/2<<endl;
  }
}
int main()
{
	#ifndef ONLINE_JUDGE
    // for getting input from input.txt
    freopen("input.txt", "r", stdin);
    // for writing output to output.txt
    freopen("output.txt", "w", stdout);
#endif
    int t;
  /*  cin>>t;
    while(t--)*/
    	solve();

}