From: Marnen Laibow-Koser Date: 2009-12-09T02:39:25+09:00 Subject: Re: Example Ruby Code Christopher Davidson wrote: > Can anybody explain how this code actually works in simple terms if > possible :). > > def animals > yield "Tiger" > yield "Giraffe" > end > > animals { |x| puts "Hello, #{x}" } Go read about blocks in Ruby. If you don't understand something once you've done that, hopefully you'll have a more specific question to ask... Best, --  Marnen Laibow-Koser http://www.marnen.org marnen@marnen.org -- Posted via http://www.ruby-forum.com/.