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

Re: use strict won't require explicit name for all variables?

by webfiend (Vicar)
on Feb 28, 2002 at 17:29 UTC ( #148298=note: print w/ replies, xml ) Need Help??


in reply to use strict won't require explicit name for all variables?

Just a quick editorial comment on $a and $b. Since so many of Perl's internal variables are indicated by Funny Characters(TM), having plain old letters for the sort variables may not quite sink in right away. It hasn't bit me in any of my own code (my problem is one of excessively verbose names rather than overly terse), but I can see how it might confuse somebody who is looking for special variables with names like $_ or $!.

Now that I think about it... I've never had any problems remembering about the regex variables $1, $2, etcetera. The context makes it quite clear what purpose they serve. Guess I just have to remember that, like so many things in Perl, $a and $b are just a question of context.

"All you need is ignorance and confidence; then success is sure."-- Mark Twain


Comment on Re: use strict won't require explicit name for all variables?
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (12)
As of 2014-11-24 20:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My preferred Perl binaries come from:














    Results (147 votes), past polls