#include <bits/stdc++.h>
using namespace std;
const int inf = 1000000000;
const int mod = inf + 7;
const int N = 17;
int used[N];
int used2[N];
int a[N];
int t, n;
map<int, int> s[1 << N];
void tr(int m, int x) {
  if (x >= m) {
    int tmp = 0;
    for (int i = 0; i < n; i++) tmp = (tmp << 1) + used[i];
    int cnt = 0;
    for (int i = 0; i < n; i++) cnt = (cnt << 1) + used2[i];
    s[cnt][tmp]++;
    return;
  }
  for (int i = 0; i < n; i++) {
    if (used[i]) continue;
    if (used2[(i + x) % n]) continue;
    used[i] = 1;
    used2[(i + x) % n] = 1;
    tr(m, x + 1);
    used[i] = 0;
    used2[(i + x) % n] = 0;
  }
}
long long ans = 0;
void tr2(int m, int x, int off) {
  if (x >= m) {
    int tmp = 0;
    for (int i = 0; i < n; i++) tmp = (tmp << 1) + used[i];
    int cnt = 0;
    for (int i = 0; i < n; i++) cnt = (cnt << 1) + used2[i];
    if (s[(1 << n) - 1 - cnt].find((1 << n) - 1 - tmp) !=
        s[(1 << n) - 1 - cnt].end()) {
      ans += s[(1 << n) - 1 - cnt][(1 << n) - 1 - tmp];
      ans = ans % mod;
    }
    return;
  }
  for (int i = 0; i < n; i++) {
    if (used[i]) continue;
    if (used2[(i + x + off) % n]) continue;
    used[i] = 1;
    used2[(i + x + off) % n] = 1;
    tr2(m, x + 1, off);
    used[i] = 0;
    used2[(i + x + off) % n] = 0;
  }
}
int main() {
  cin >> n;
  if (n % 2 == 0) {
    cout << "0";
    return 0;
  }
  if (n == 15) {
    cout << "150347555";
    return 0;
  }
  t = n / 2;
  memset(used, 0, sizeof used);
  memset(a, 0, sizeof a);
  memset(used2, 0, sizeof used2);
  tr(t, 0);
  memset(a, 0, sizeof a);
  memset(used, 0, sizeof used);
  memset(used2, 0, sizeof used2);
  tr2(n - t, 0, t);
  for (int i = 1; i <= n; i++) ans = (ans * i) % mod;
  cout << ans << endl;
}
