Sponsoring website: Emergency Boot Kit

A few PERL Programs
from The Starman


Hopefully these programs can help you in learning / understanding
the PERL programming language.


Simple stand-alone perl (.PL) Scripts

sortdata.pl.txt is an 'Introduction to Perl by example' using the highly commented script of a simple Perl program. The program sorts an input file line by line, then writes the sorted lines to a separate output file.  Could be useful as a 'template' for anyone starting to write a Perl program for the first time.

ip2ipf.pl.txt This may be useful to someone using IP Addresses in a database: It takes a list of IP#s (one per line) and creates an output file with evenly spaced IP#s of 3 digits per group using leading zeros where necessary making it possible to sort correctly by IP Address.
ipf2ip.pl.txt This script simply reverses the effect of that above by removing any leading zeros from a list of IP Addresses.


perl-CGI Scripts

Environ.cgi.txt This "CGI script" (written in Perl) can be very useful in helping you write other scripts for a particular server. It lists out all of the Environment Variables and their values of the Server; no more guessing as to which variables your particular server supports! (As usual, you may need to edit the "Shebang" line to match the location of your server's perl executable. I used: #!/usr/local/bin/perl )




Here's a single-page ... Introduction to Perl
From Campus Computing, University of Missouri - Columbia.
This course presumes participants have elementary programming experience in a procedural programming language such as C, Pascal, or Basic; and access to a system with at least Perl 4 installed. By completing this course and its homework, you should be able to:
  1. Locate reference materials and other resources related to Perl;
  2. Express fundamental programming constructs such as variables, arrays, loops, subroutines and input/output in Perl;
  3. Understand several concepts relatively idiosyncratic to Perl, such as associative arrays, Perl regular expressions, and system interfaces;
  4. Program in Perl for data manipulation, file maintenance, packaging or interfacing system facilities, and for "Common Gateway Interface" Web applications.

Please USE Your Browser's BACK BUTTON . . . . . or

Visit The Starman's Perl Homepage