Use Fixnum#times Use for i in 1..10 puts 'My iteration' end Rather than 5.times do puts 'My iteration' end