#include #include #include #include using namespace std; using ull = unsigned long long; #define Mod %1000000007 ull a(int n) { if (n <= 1) return 1; if (n % 2 == 0) { ull am = 0; for (int i = n - 1; i > 0; i -= 2) am += a(i); return n * (am Mod); } else { ull am = 0; for (int i = n - 1; i > 0; i -= 2) am += a(i); return n * (am Mod); } } int main() { int n; cin >> n; cout << a(n)Mod << endl; return 0; }