Created
August 30, 2010 03:08
-
-
Save mfollett/556962 to your computer and use it in GitHub Desktop.
functional programming blog, week 2 example 3
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
my $fun | |
{ | |
my $value = 42; | |
$fun = sub {$value}; | |
} | |
say $fun->(); # prints "42\n" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment