Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
Sorry, I seemed to have missed an email detailing this comment.
Your solution is close but realize that Array.map will return an array with the block executed on each element of the array!
So you should be making sure to return the
sum
would be a good idea..each
will only allow 1 parameter for the block so you cannot do:numbers.each {|total, i| total += i}
You can do
numbers.each { |i| total += i }
but you'll need total be done in some other way.