Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re^3: Local for lexicals

by Roy Johnson (Monsignor)
on Aug 13, 2009 at 14:10 UTC ( [id://788301]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #!perl
    use strict;
    ...
    $closure->($_, $_+1) for (1..4);
    
    print "And my X is $x\n";
    
  2. or download this
    my $closure = sub {
      my ($x, $y) = @_;
      print "Got $x and $y\n";
    };
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://788301]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (4)
As of 2024-03-28 21:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found