Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re^5: Have you netted a Perl Monk or Perl Pretender in 5 minutes or less?

by QM (Parson)
on Sep 15, 2005 at 18:22 UTC ( [id://492366]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/perl -w 
    use strict;
    ...
    print "Before: c=$c\n";
    my $c = 1 unless $c;
    print "After:  c=$c\n";
    
  2. or download this
    "my" variable $c masks earlier declaration in same scope at 492281.pl 
    +line 6.
    
  3. or download this
    our $c = 2;
    
  4. or download this
    print "Before: c=$c\n";
    
  5. or download this
    my $c = 1 unless $c;
    
  6. or download this
    print "After:  c=$c\n";
    
  7. or download this
    Use of uninitialized value in concatenation (.) or string at 492281.pl
    + line 7.
    
  8. or download this
    #!/usr/bin/perl -w
    use strict;
    ...
    print "Before: c=$c\n";
    my $d = 1 unless $c;
    print "After:  d=$d\n";
    
  9. or download this
    Before: c=2
    Use of uninitialized value in concatenation (.) or string at 492281.pl
    + line 7.
    After:  d=
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others scrutinizing the Monastery: (5)
As of 2024-04-24 09:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found