結果

問題 No.523 LED
ユーザー kotatsugamekotatsugame
提出日時 2017-09-21 02:13:00
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
AC  
実行時間 328 ms / 2,000 ms
コード長 221 bytes
コンパイル時間 586 ms
コンパイル使用メモリ 65,632 KB
実行使用メモリ 6,948 KB
最終ジャッジ日時 2024-04-25 21:26:35
合計ジャッジ時間 3,250 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
6,812 KB
testcase_01 AC 2 ms
6,940 KB
testcase_02 AC 6 ms
6,940 KB
testcase_03 AC 2 ms
6,940 KB
testcase_04 AC 2 ms
6,944 KB
testcase_05 AC 326 ms
6,940 KB
testcase_06 AC 2 ms
6,940 KB
testcase_07 AC 2 ms
6,940 KB
testcase_08 AC 2 ms
6,940 KB
testcase_09 AC 3 ms
6,948 KB
testcase_10 AC 2 ms
6,940 KB
testcase_11 AC 2 ms
6,940 KB
testcase_12 AC 2 ms
6,944 KB
testcase_13 AC 64 ms
6,940 KB
testcase_14 AC 2 ms
6,944 KB
testcase_15 AC 2 ms
6,944 KB
testcase_16 AC 2 ms
6,940 KB
testcase_17 AC 2 ms
6,944 KB
testcase_18 AC 328 ms
6,940 KB
testcase_19 AC 118 ms
6,940 KB
testcase_20 AC 105 ms
6,940 KB
testcase_21 AC 247 ms
6,944 KB
testcase_22 AC 275 ms
6,940 KB
testcase_23 AC 275 ms
6,940 KB
testcase_24 AC 8 ms
6,940 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
main.cpp:5:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    5 | main()
      | ^~~~

ソースコード

diff #

#include<iostream>
using namespace std;
long M=1e9+7;
long pow(long a,int b){return b?pow(a*a%M,b/2)*(b%2?a:1)%M:1;}
main()
{
	long n,m,ans=1;cin>>n;
	for(m=n*2;m>0;m--)ans=ans*m%M;
	cout<<ans*pow(pow(2,n),M-2)%M<<endl;
}
0