Class: SimpleMath::Calculator
- Inherits:
-
Object
- Object
- SimpleMath::Calculator
- Defined in:
- lib/simple_math/calculator.rb
Overview
Calculator
Instance Attribute Summary collapse
-
#start ⇒ Object
Returns the value of attribute start.
Class Method Summary collapse
Instance Attribute Details
#start ⇒ Object
Returns the value of attribute start.
6 7 8 |
# File 'lib/simple_math/calculator.rb', line 6 def start @start end |
Class Method Details
.run(start: 0, &block) ⇒ Object
8 9 10 |
# File 'lib/simple_math/calculator.rb', line 8 def self.run(start: 0, &block) new(start: start).send(:calculate, &block) end |