結果

問題 No.53 悪の漸化式
ユーザー yuruhiyayuruhiya
提出日時 2020-03-27 19:35:36
言語 Ruby
(3.3.0)
結果
WA  
実行時間 -
コード長 103 bytes
コンパイル時間 203 ms
コンパイル使用メモリ 11,560 KB
実行使用メモリ 15,332 KB
最終ジャッジ日時 2023-08-30 16:45:23
合計ジャッジ時間 2,620 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 80 ms
15,132 KB
testcase_01 AC 75 ms
15,132 KB
testcase_02 AC 76 ms
15,240 KB
testcase_03 AC 79 ms
15,064 KB
testcase_04 AC 80 ms
15,092 KB
testcase_05 AC 75 ms
15,128 KB
testcase_06 AC 75 ms
15,332 KB
testcase_07 AC 75 ms
15,148 KB
testcase_08 AC 74 ms
15,312 KB
testcase_09 AC 75 ms
15,292 KB
testcase_10 AC 74 ms
15,180 KB
testcase_11 AC 75 ms
15,128 KB
testcase_12 AC 75 ms
15,128 KB
testcase_13 AC 75 ms
15,264 KB
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 WA -
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

a, b = 4.0, 3.0
gets.to_i.times do |i|
    a, b = b, (19 * b - 12 * a) / 4
end
puts sprintf("%.12f", a)
0