Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re^3: Why should I use perl 5.10?

by duff (Vicar)
on Dec 13, 2007 at 17:42 UTC ( #656868=note: print w/replies, xml ) Need Help??


in reply to Re^2: Why should I use perl 5.10?
in thread Why should I use perl 5.10?

I think the OP means "state variables" as that's what they are called in Perl 6. The declarator is the word state too.

sub foo { state $x = 0; # $x will retain it's state through # successive invocations of foo() # ... }
(Yes, other languages use the keyword static, but this is Perl!)

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://656868]
help
Chatterbox?
beech oh my *me my*
beech cannot replicate
beech stupid 3d printer
[rajesh_perl]: hi
[Discipulus]: good morning monks! or whatever timezone you are experiencing

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (6)
As of 2017-03-28 07:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (327 votes). Check out past polls.