From: dblack@... Date: 2006-08-12T08:57:37+09:00 Subject: Re: Beginner's question: assigning same value to many variables Hi -- On Sat, 12 Aug 2006, Mark Van Holstyn wrote: > or you could do > > %w{ a b c d e f g h i j }.each {|v| eval "#{v}=''" } That won't work; they'll go out of scope. Actually out of two scopes: the eval scope, and the #each block scope. David -- http://www.rubypowerandlight.com => Ruby/Rails training & consultancy ----> SEE SPECIAL DEAL FOR RUBY/RAILS USERS GROUPS! <----- http://dablog.rubypal.com => D[avid ]A[. ]B[lack's][ Web]log http://www.manning.com/black => book, Ruby for Rails http://www.rubycentral.org => Ruby Central, Inc.