Advanced Perl Features Used in this Class

Perl Construct Example Description and Link
q, qq, qx, qw $string = qq{He said, "Hello, world!"}; Alternate Quoting Styles
and, or $errors < 100 or die "Too many errors!"; Logical And and Logical Or
$| $| = 1 Autoflush Operator
m//x $file =~ m{ ^/usr/sbin }x Easier-to-Understand Regular Expressions
use use CGI; Using Perl Modules
::
->
Getopt::Std
$q->dump
Object-Oriented Programming in Perl
carpout use CGI::Carp qw (carpout);
carpout(\*STDOUT);
Redirecting Errors to the Browser (preferred argument is a reference to a typeglob) instead of server's error log
<=> return $a <=> $b; Numeric Comparison Operator

 
Dan Keller Technical Services © 2000