Sum the value of array in hash March 21, 2023 by Tarik Ruby versions >= 2.4.0 has an Enumerable#sum method. So you can do arr.sum {|h| h[:amount] }