http://qs321.pair.com?node_id=1217320


in reply to Print contents of text file line by line

Here's one way to do it</p.

#!/usr/bin/perl use strict;use warnings; print while ( <> );

You'd run it by invoking the program name followed by the name of the text file: program.pl textfile.txt