As I showed in my article here, we can have another way of doing this job: 1234567require ‘prime’ goal = 600851475143 Prime.each(goal) do |number|    @container = [number] end puts @container.last This small piece of code illustrates togeter with my other solutions, that we have a vast amount of ways doing things in Ruby …

Read more at the source