結果

問題 No.727 仲介人moko
ユーザー milanis48663220
提出日時 2020-07-03 01:08:47
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 7 ms / 1,000 ms
コード長 517 bytes
コンパイル時間 1,189 ms
コンパイル使用メモリ 81,976 KB
実行使用メモリ 5,376 KB
最終ジャッジ日時 2024-09-15 12:55:58
合計ジャッジ時間 1,894 ms
ジャッジサーバーID
(参考情報)
judge1 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 25
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <algorithm>
#include <iomanip>
#include <vector>
#include <queue>
#include <set>
#include <map>

using namespace std;
typedef long long ll;
const ll MOD = 1000000007;

int main(){
    ios::sync_with_stdio(false);
    cin.tie(0);
    cout << setprecision(10) << fixed;
    ll ans = 1;
    ll fac = 1;
    ll fac2 = 1;
    ll N; cin >> N;
    for(ll i = 1; i <= N; i++){
        fac *= i; fac %= MOD;
        fac2 *= 2*i-1; fac2 %= MOD;
    }
    cout << ((fac*fac)%MOD*fac2)%MOD << endl;
}
0