--001485f87284568c6b048b4dd6ee Content-Type: text/plain; charset=ISO-8859-1 Ali, I suspect the example you're trying was actually printing out value*s*(...s! plural NOT value) this would then make sense as a demonstration that the 'each' loop did not alter the array :) On Wed, Jul 14, 2010 at 12:26 AM, Abder-Rahman Ali < abder.rahman.ali / gmail.com> wrote: > I have written this a script like this: > > values 10, 20, 30].each {|value| value + (value * 10)} > > puts value > > In this case, I get: > undefined local variable or method `value' for main:Object (NameError) > > I'm trying to see the result of the equation value + (value * 10) > > What should I do? > > Thanks. > -- > Posted via http://www.ruby-forum.com/. > > --001485f87284568c6b048b4dd6ee--