lib/lottery/taiwan.rb in lottery-0.0.4 vs lib/lottery/taiwan.rb in lottery-0.0.5

- old
+ new

@@ -11,12 +11,25 @@ # Lotto649 def lotto_649 make_hash(draw(49, 6)) end - # Daily Cash - def daily_cash + # Daily Cash 539 + def daily_cash_539 make_hash(draw(39, 5)) end + def three_stars + digit_draw + end + + def four_stars + digit_draw(4) + end + + private + + def digit_draw(digits=3) + ('0' * digits ..'9' * digits).to_a.sample + end end end \ No newline at end of file