Created
May 27, 2010 16:04
-
-
Save myronmarston/415986 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>> p = Proc.new { |a, b| a } | |
=> #<Proc:0x00000001036962f8@(irb):2> | |
>> p.call(5) | |
=> 5 | |
>> l = lambda { |a, b| a } | |
=> #<Proc:0x000000010368e8c8@(irb):4> | |
>> l.call(5) | |
ArgumentError: wrong number of arguments (1 for 2) | |
from (irb):4 | |
from (irb):5:in `call' | |
from (irb):5 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment