#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; typedef vector VI; typedef vector VVI; typedef vector VS; typedef pair PII; typedef long long ll; #define FOR(i,a,b) for(int i=(a);i<(b);++i) #define REP(i,n) FOR(i,0,n) int main() { ll N; cin >> N; ll a = 1; ll b; for (ll i = 1; i <= N ; ++i){ b = (i % 1000000007) * (2 * (i % 1000000007) - 1) * a % 1000000007; a = b; } cout << a << endl; return 0; }