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

Re: Useless use of private variable

by jbt (Chaplain)
on Jul 15, 2009 at 03:01 UTC ( [id://780139]=note: print w/replies, xml ) Need Help??


in reply to Useless use of private variable

$s is only useful in the for loop:

sub validate { my ($p,$s_no) = @_; for (my $s = 0; $s<=$s_no; $s++) { my $command = $CFG::CFG[$s]->{'CMD'}; if ($command =~ /cd /) { $$p = $$p - 1; } } }

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (6)
As of 2024-04-24 06:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found