3 ms·
Looks like you need to indent that code (1..5).map{|n| n**n}.reduce(:*) == 24 * 60 * 60 * 1000 Or if we're golfing (1..5).reduce{|t,n|t*n**n}
by godd2 9y ago
Looks like you need to indent that code
(1..5).map{|n| n**n}.reduce(:*) == 24 * 60 * 60 * 1000
Or if we're golfing
(1..5).reduce{|t,n|t*n**n}