Class: LOTTO::L
- Inherits:
-
Object
- Object
- LOTTO::L
- Defined in:
- lib/toychest/lotto.rb
Instance Attribute Summary collapse
-
#ticket ⇒ Object
readonly
Returns the value of attribute ticket.
Instance Method Summary collapse
-
#initialize(k) ⇒ L
constructor
A new instance of L.
- #run ⇒ Object
- #win?(w) ⇒ Boolean
Constructor Details
#initialize(k) ⇒ L
Returns a new instance of L.
17 18 19 20 21 22 |
# File 'lib/toychest/lotto.rb', line 17 def initialize k @id = k if !ticket run end end |
Instance Attribute Details
#ticket ⇒ Object (readonly)
Returns the value of attribute ticket.
16 17 18 |
# File 'lib/toychest/lotto.rb', line 16 def ticket @ticket end |