結果

問題 No.236 鴛鴦茶
ユーザー what_alnkwhat_alnk
提出日時 2015-12-26 21:19:49
言語 Ruby
(3.3.0)
結果
WA  
実行時間 -
コード長 166 bytes
コンパイル時間 49 ms
コンパイル使用メモリ 11,868 KB
実行使用メモリ 16,060 KB
最終ジャッジ日時 2023-10-19 04:21:04
合計ジャッジ時間 3,488 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 AC 90 ms
16,060 KB
testcase_05 AC 90 ms
16,060 KB
testcase_06 AC 91 ms
16,060 KB
testcase_07 AC 93 ms
16,060 KB
testcase_08 AC 90 ms
16,060 KB
testcase_09 AC 89 ms
16,060 KB
testcase_10 AC 88 ms
16,060 KB
testcase_11 AC 89 ms
16,060 KB
testcase_12 AC 90 ms
16,060 KB
testcase_13 AC 88 ms
16,060 KB
testcase_14 AC 88 ms
16,060 KB
testcase_15 AC 88 ms
16,060 KB
testcase_16 AC 89 ms
16,060 KB
testcase_17 AC 90 ms
16,060 KB
testcase_18 AC 88 ms
16,060 KB
testcase_19 AC 89 ms
16,060 KB
testcase_20 WA -
testcase_21 AC 89 ms
16,060 KB
testcase_22 AC 89 ms
16,060 KB
testcase_23 AC 92 ms
16,060 KB
testcase_24 AC 88 ms
16,060 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

a, b, x, y = gets.chomp.split(" ").map(&:to_f)

r = []
rx = x * b / a
if  rx < y then
  r << x + rx
end

ry = y * a / b
if  ry < x then
  r << ry + y
end

puts r.max
0