Understanding Ruby Blocks, Procs and Lambdas

Posted in Ruby on Rails, Websites or Tools

I thought that I understood Ruby a little bit, but after reading Robert Sosinski’s article on Blocks, Procs and Lamdas in Ruby I felt a little humbled. To take such a small part of a language and express such detail and give some very useful examples really impressed me. The similarities between some of the ways I do things using Javascript and his examples really surprised me too.

I’d recommend giving it a good read to really understand how things work with these constructs and it may even give you a few new ideas on how to approach some problems you’ve encountered along the way.

No Comments

No comments have been left yet, be the first.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Twitter

The latest @rubyfive podcast is up, our own @sj26 receiving a mention for Ruby 1.9.3 performance improvements. http://t.co/hfx3EPMz

@frontiergroup about 6 days ago #

Search Posts

Featured Posts

Categories

Archives

View more archives