結果

問題 No.212 素数サイコロと合成数サイコロ (2)
ユーザー suppy193suppy193
提出日時 2015-06-18 10:47:48
言語 Ruby
(3.3.0)
結果
AC  
実行時間 85 ms / 5,000 ms
コード長 216 bytes
コンパイル時間 58 ms
コンパイル使用メモリ 11,380 KB
実行使用メモリ 15,624 KB
最終ジャッジ日時 2023-08-27 00:00:11
合計ジャッジ時間 2,157 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 84 ms
15,196 KB
testcase_01 AC 83 ms
15,544 KB
testcase_02 AC 82 ms
15,372 KB
testcase_03 AC 81 ms
15,516 KB
testcase_04 AC 82 ms
15,624 KB
testcase_05 AC 85 ms
15,444 KB
testcase_06 AC 83 ms
15,524 KB
testcase_07 AC 84 ms
15,396 KB
testcase_08 AC 85 ms
15,400 KB
testcase_09 AC 82 ms
15,560 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

p, c = gets.chomp.split(' ')
p = p.to_i
c = c.to_i
p_set = [2, 3, 5, 7, 11, 13]
c_set = [4, 6, 8, 9, 10, 12]
p_expect = p_set.inject(:+) / 6.0
c_expect = c_set.inject(:+) / 6.0
puts (p_expect ** p) * (c_expect ** c)
0