Skip to content

Instantly share code, notes, and snippets.

@tcrayford
Created August 25, 2011 20:27
Show Gist options
  • Save tcrayford/1171808 to your computer and use it in GitHub Desktop.
Save tcrayford/1171808 to your computer and use it in GitHub Desktop.
>> foo = 1
>> x = lambda { if foo == 0; return foo; else; foo = foo - 1; x.call; end }
=> #<Proc:0x0000000106b9bd40@(irb):16>
>> x.call
=> 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment