結果

問題 No.73 helloworld
ユーザー finefine
提出日時 2016-03-24 01:06:12
言語 Ruby
(3.3.0)
結果
AC  
実行時間 88 ms / 5,000 ms
コード長 291 bytes
コンパイル時間 67 ms
コンパイル使用メモリ 11,380 KB
実行使用メモリ 15,344 KB
最終ジャッジ日時 2023-09-11 23:55:49
合計ジャッジ時間 2,574 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 88 ms
15,152 KB
testcase_01 AC 83 ms
15,328 KB
testcase_02 AC 85 ms
15,164 KB
testcase_03 AC 84 ms
15,164 KB
testcase_04 AC 84 ms
15,264 KB
testcase_05 AC 82 ms
15,164 KB
testcase_06 AC 84 ms
15,036 KB
testcase_07 AC 84 ms
15,144 KB
testcase_08 AC 83 ms
15,296 KB
testcase_09 AC 83 ms
15,328 KB
testcase_10 AC 84 ms
15,344 KB
testcase_11 AC 85 ms
15,296 KB
testcase_12 AC 84 ms
15,128 KB
testcase_13 AC 82 ms
15,156 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

d,e,h,l,o,r,w = STDIN.map(&:to_i).values_at(3,4,7,11,14,17,22)
if d < 1 || e < 1 || h < 1 || l < 3 || o < 2 || r < 1 || w < 1
    p 0
else
    ans = 0
    2.upto(l - 1){|a|
        ans = [ans, a * (a - 1) / 2 * (l - a)].max
        }
    p d * e * h * r * w * (o / 2) * (o - o / 2) * ans
end
0