From: Lionel Thiry Date: 2005-11-21T13:02:26+09:00 Subject: Re: return in blocks Lyndon Samson a �crit : > Whats the official word on using return to return a value in a block, > rather than just the value of the last expression? return in a block doesn't just return the block, it returns the method where the block has been created. Exemple: def my_method test = ["one", "two", "three"] test.each do |e| if e == "three" return "my_method returned" end puts e end puts "will it ever goes here?" end puts my_method output: one two my_method_returned -- Lionel Thiry Personal web site: http://users.skynet.be/lthiry/