Hello,

I changed from ruby koans to rubymonks.

Now I have to make a method which can substract any number of numbers.

So I tried this

def subtract(*numbers)

numbers.inject(0) { |sum, number| sum - number }

end

but that won’t work subtract ( 4,5) gives -9 when -1 is the right

answer.

Can anyone give me a tip for a better answer.

Roelof