Discovering the Differences Between Blocks, Procs and Lambdas

Part of Screencast Series: Ruby Metaprogramming Revealed

Published September 2015

Unblock using procs in Ruby

Ruby developers love blocks and use them every day, however in many cases the blocks are executing immediately. What if you’d like to execute the block later? In this video we are going to discuss callable objects: blocks (which are actually not objects), procs and lambdas. We’ll see the differences between them and reveal the truth about closures.


Have your say! or become a member now to take part in the discussion

Meet your instructor
Ilya Bodrov-Krukowski

Ilya is a lecturer at MATI-RSTU, senior engineer at Campaigner LLC and seasoned author at SitePoint. When Ilya is not working away on new projects or contributing to open source projects, he's expanding and refining his skills in HTML, CSS, jQuery, Angular, Backbone and Rails. You can read all about his work and development discoveries on his blog Radiant Wind.