[Kc] Perl Noob

Eric Wilhelm scratchcomputing at gmail.com
Wed Sep 19 13:10:23 PDT 2007

# from Andrew Moore
# on Wednesday 19 September 2007 12:49:

>First, instead of using #!/usr/bin/perl -w at the top, let's get rid
>of '-w' and do 'use warnings' instead. The difference is subtle, but
>essentially we just want to enforce warnings on your code, not on all
>modules you may have included (which for now is none). Also, let's add
>'use strict', too.

Maybe my mail isn't reaching the list (or there's an echo?)  Oh well, 
moving on...

 use warnings;
 use strict;
 print join("\n",
   map({"$_ is " .
     (exists($ENV{$_}) ?
       (defined($ENV{$_}) ? $ENV{$_} : '-undef-') :
   } @ARGV)
 ), "\n";

Consumers want choice, consumers want openness.
--Rob Glaser

More information about the kc mailing list