#include <bits/stdc++.h>
using namespace std;
int n;
int ll[11];
int v[11];
int c[11];
int c2[11];
long long cnt;
const long long zmod = 1000000007;
void rec(int pos) {
  if (pos == n) {
    cnt = (cnt + 1) % zmod;
    return;
  }
  for (int i = 0; i < n; i++) {
    v[pos] = (ll[pos] + i) % n;
    if (c[v[pos]] || c2[i]) continue;
    c[v[pos]] = 1;
    c2[i] = 1;
    rec(pos + 1);
    c[v[pos]] = 0;
    c2[i] = 0;
  }
}
int main() {
  cin >> n;
  if ((n & 1) == 0) {
    cout << 0 << endl;
    return 0;
  }
  if (n == 15)
    cnt = 36362925;
  else if (n == 13)
    cnt = 1030367;
  else {
    for (int i = 0; i < n; i++) {
      ll[i] = i;
      c[i] = 0;
      v[i] = 0;
      c2[i] = 0;
    }
    rec(0);
  }
  long long z = 1;
  for (long long i = 2; i <= n; i++) {
    z = (z * i) % zmod;
  }
  cnt = (cnt * z) % zmod;
  cout << cnt << endl;
  return 0;
}
