#include <cstdio>
#include <ctime>
#include <cstdlib>
#include <cstring>
#include <queue>
#include <string>
#include <set>
#include <stack>
#include <map>
#include <cmath>
#include <vector>
#include <iostream>
#include <algorithm>
using namespace std;

#define FF(i, a, b) for(int i = (a); i < (b); ++i)
#define FD(i, b, a) for(int i = (b) - 1; i >= (a); --i)
#define FE(i, a, b) for(int i = (a); i <= (b); ++i)
#define FED(i, b, a) for(int i = (b); i>= (a); --i)
#define REP(i, N) for(int i = 0; i < (N); ++i)
#define CLR(A,value) memset(A,value,sizeof(A))
#define FC(it, c) for(__typeof((c).begin()) it = (c).begin(); it != (c).end(); it++)

#define SZ(V) (int)V.size()
#define PB push_back
#define EQ(a, b) (fabs((a) - (b)) <= EPS)

//INPUT
#define RI(n) scanf("%d", &n)
#define RII(n, m) scanf("%d%d", &n, &m)
#define RIII(n, m, k) scanf("%d%d%d", &n, &m, &k)
#define RIV(n, m, k, p) scanf("%d%d%d%d", &n, &m, &k, &p)
#define RV(n, m, k, p, q) scanf("%d%d%d%d%d", &n, &m, &k, &p, &q)
#define RS(s) scanf("%s", s)

typedef long long LL;
typedef unsigned long long ULL;
typedef vector <int> VI;
const int INF = 1000000000;

int n, visit[2][1100];
LL ans;

void dfs(int x, int y, int cnt)
{
    if (cnt == n)
    {
        ans++;
        //cout << x <<y <<endl;
        ans %= 1000000007;
        return;
    }
    if (x == 0 && !visit[1][y])
    {
        visit[1][y] = 1;
        dfs(1, y, cnt + 1);
        visit[1][y] = 0;
    }
    if (x == 1 && !visit[0][y])
    {
        visit[0][y] = 1;
        dfs(0, y, cnt + 1);
        visit[0][y] = 0;
    }
    if (y > 1 && !visit[x][y - 1])
    {
        visit[x][y - 1] = 1;
        dfs(x, y - 1, cnt + 1);
        visit[x][y - 1] = 0;
    }
    if (y < n && !visit[x][y + 1])
    {
        visit[x][y + 1] = 1;
        dfs(x, y + 1, cnt + 1);
        visit[x][y + 1] = 0;
    }
    if (x == 0 && y > 1 && !visit[1][y - 1])
    {
        visit[1][y - 1] = 1;
        dfs(1, y - 1, cnt + 1);
        visit[1][y - 1] = 0;
    }
    if (x == 0 && y < n && !visit[1][y + 1])
    {
        visit[1][y + 1] = 1;
        dfs(1, y + 1, cnt + 1);
        visit[1][y + 1] = 0;
    }
    if (x == 1 && y < n && !visit[0][y + 1])
    {
        visit[0][y + 1] = 1;
        dfs(0, y + 1, cnt + 1);
        visit[0][y + 1] = 0;
    }
    if (x == 1 && y > 1 && !visit[0][y - 1])
    {
        visit[0][y - 1] = 1;
        dfs(0, y - 1, cnt + 1);
        visit[0][y - 1] = 0;
    }
}

int main()
{
    while (cin >> n)
    {
        int m = n, mid = 0;
        LL res = 0;
        if (n % 2)
            mid = (n + 1) / 2;
        m = --m / 2 + 1;
        FE(i, 1, n)
        {
            CLR(visit, 0);
            ans = 0;
            dfs(0, i, 1);
            res += ans;
//            cout << ans << ' ';
//            if (n % 2 && i == mid)
//                res += (2 * ans) % 1000000007;
//            else
//                res += (4 * ans) % 1000000007;
        }
        cout << res * 2<< endl;
    }
}