Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re^3: Global Vars

by roboticus (Chancellor)
on Sep 04, 2009 at 15:01 UTC ( [id://793477]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my %my_global_values = (foo=>0, etc=>0);
    my $rGlobals = \%my_global_values;
    sub zigafoo { $rGlobals-> = 7 }
    
  2. or download this
    package barbaz;
    my %my_package_values = (foo=>0);
    my $rPackage = \%my_package_values;
    sub foobar { $rPackage->{foo} = 7; }
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others meditating upon the Monastery: (3)
As of 2024-03-29 01:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found