From: "Jan E." Date: 2012-09-04T17:29:37+09:00 Subject: Re: how to sum element of array Hi, In newer versions of Ruby (1.9) you can use sum = a_array.reduce :+ See http://ruby-doc.org/core-1.9.3/Enumerable.html#method-i-reduce -- Posted via http://www.ruby-forum.com/.