Hi listers, I want to read several text files into a single string.
use strict;
@ARGV=('fil1','fil2','fil3');
my $fil = do{local $/; <>};
print $fil;
__END__
This prints only the contents of fil1.
If I use an array:
use strict;
@ARGV=('fil1','fil2','fil3');
my @fil = do{local $/; <>};
print @fil;
__END__
All 3 files are printed, but there are 3 strings in @fil.
I may misunderstand "concatenation", as I read <> should do.
What construct would yield a single string ?
Thanks
