#include using namespace std; bool vis[100][100]; int dx[4] = {0, 0, 1, -1}; int dy[4] = {1, -1, 0, 0}; long long int ans; void backtr(int lin, int col, int moves) { if (!moves) { ++ ans; return ; } int nx, ny; for (int k = 0; k < 4; ++ k) { nx = lin + dx[k]; ny = col + dy[k]; if (!vis[nx][ny]) { vis[nx][ny] = true; backtr(nx, ny, moves - 1); vis[nx][ny] = false; } } } int main() { int n; cin >> n; if (n == 1) { cout << "1\n"; return 0; } n --; vis[50][50] = true; backtr(50, 50, n); cout << (ans) / 2 << '\n'; return 0; }