Sha256: 47217ffa0698e263331a452d0c82850337c4affc737fea087063d2076ea1627b

Contents?: true

Size: 152 Bytes

Versions: 3

Compression:

Stored size: 152 Bytes

Contents

class Calculator
  def push(n)
    @args ||= []
    @args << n
  end

  def add
    #@args[0] + @args[1]
    @args.inject(0){|n,sum| sum + n}
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
cucumber-3.0.1 examples/i18n/ro/lib/calculator.rb
cucumber-3.0.0 examples/i18n/ro/lib/calculator.rb
cucumber-3.0.0.pre.2 examples/i18n/ro/lib/calculator.rb