Let X = 10^{100}. Inaba has N checker pieces on the number line, where the i-th checker piece is at coordinate X^{i} for all 1 \leq i \leq N.

Every second, Inaba chooses two checker pieces, A and B, and move A to the symmetric point of its current position with respect to B. After that, B is removed. (It is possible that A and B occupy the same position, and it is also possible for A to occupy the same position as another checker piece after the move).

After N - 1 seconds, only one checker piece will remain. Find the number of distinct possible positions of that checker piece, modulo 10^{9} + 7.

Constraints

* 1 \leq N \leq 50
* N is an integer.

Input

Input is given from Standard Input in the following format:


N


Output

Print the number of distinct possible positions of the final checker piece, modulo 10^{9} + 7.

Examples

Input

3


Output

12


Input

4


Output

84


Input

22


Output

487772376
#ifndef BZ
#pragma GCC optimize "-O3"
#endif
#include <bits/stdc++.h>

#define FASTIO

#ifdef FASTIO
#define scanf abacaba
#define printf abacaba
#endif

typedef long long ll;
typedef long double ld;
typedef unsigned long long ull;

using namespace std;


/*
ll pw(ll a, ll b) {
	ll ans = 1; while (b) {
		while (!(b & 1)) b >>= 1, a = (a * a) % MOD;
		ans = (ans * a) % MOD, --b;
	} return ans;
}
*/
const ll MOD = 1e9 + 7;

void add(ll &a, ll b) {
	a += b;
	if (a >= MOD)
		a -= MOD;
}
const int MX = 55;

ll dp[MX][MX][2 * MX];
int n;
ll cnk[MX][MX];

int main() {
#ifdef FASTIO
	ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
#endif
	for (int i = 0; i < MX; ++i)
		for (int j = 0; j < MX; ++j) {
			if (i == j || j == 0)
				cnk[i][j] = 1;
			else if (j > i)
				cnk[i][j] = 0;
			else
				cnk[i][j] = (cnk[i - 1][j] + cnk[i - 1][j - 1]) % MOD;
		}
	cin >> n;
	dp[0][0][MX] = 1;
	ll ans = 0;
	for (int i = 0; i < n; ++i) {
		for (int j = 0; j < n; ++j)
			for (int k = 0; k < 2 * MX; ++k) {
				for (int a = 0; j + a < n; ++a)
					for (int b = 0; j + a + b < n; ++b) {
						if (a + b == 0)
							continue;
						if (k - MX > b)
							continue;
						if (MX - k > a)
							continue;
						int nk = k - MX;
						int na = a + nk;
						int nb = b - nk;
						nk = na - nb + MX;
						if (nk >= 0 && nk < 2 * MX)
							add(dp[i + 1][j + a + b][nk], dp[i][j][k] * cnk[j + a + b][a] % MOD * cnk[j + b][b] % MOD);
					}
			}
		add(ans, dp[i][n - 1][MX + 1] * n % MOD);
		add(ans, dp[i][n - 1][MX] * n % MOD);
	}
	cout << ans << "\n";
	return 0;
}


