- or download this
use strict;
use warnings;
- or download this
use File::Slurp qw( read_file );
my $projectA = read_file('projecta.txt');
my $projectB = read_file('projectb.txt');
- or download this
sub read_file {
my $filename = shift;
...
return <$fh>; # enjoy auto-close of $fh :)
}