結果

問題 No.523 LED
ユーザー ikdikd
提出日時 2017-06-02 23:34:35
言語 Ruby
(3.3.0)
結果
TLE  
(最新)
AC  
(最初)
実行時間 -
コード長 133 bytes
コンパイル時間 456 ms
コンパイル使用メモリ 11,868 KB
実行使用メモリ 16,088 KB
最終ジャッジ日時 2023-10-22 01:46:14
合計ジャッジ時間 15,089 ms
ジャッジサーバーID
(参考情報)
judge9 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 87 ms
16,088 KB
testcase_01 AC 86 ms
16,088 KB
testcase_02 AC 109 ms
16,088 KB
testcase_03 AC 88 ms
16,088 KB
testcase_04 AC 90 ms
16,088 KB
testcase_05 TLE -
testcase_06 AC 86 ms
16,088 KB
testcase_07 AC 90 ms
16,088 KB
testcase_08 AC 87 ms
16,088 KB
testcase_09 AC 100 ms
16,088 KB
testcase_10 AC 87 ms
16,088 KB
testcase_11 AC 88 ms
16,088 KB
testcase_12 AC 88 ms
16,088 KB
testcase_13 AC 484 ms
16,088 KB
testcase_14 AC 88 ms
16,088 KB
testcase_15 AC 89 ms
16,088 KB
testcase_16 AC 87 ms
16,088 KB
testcase_17 AC 89 ms
16,088 KB
testcase_18 TLE -
testcase_19 AC 828 ms
16,088 KB
testcase_20 AC 740 ms
16,088 KB
testcase_21 AC 1,637 ms
16,088 KB
testcase_22 AC 1,830 ms
16,088 KB
testcase_23 AC 1,835 ms
16,088 KB
testcase_24 AC 126 ms
16,088 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.rb:4: warning: assigned but unused variable - q
Syntax OK

ソースコード

diff #

n=gets.to_i

mod=10**9+7
q=1
t=(1..n).inject{|res, i| res=(res*i)%mod}
u=(1..n).inject{|res, i| res=(res*(2*i-1))%mod}

puts t*u%mod
0