# WARNING: This is a very basic question -
Maybe only the beginners
should answer it?#! perl use strict; use warnings;
my ($first, $last, $out) = '';
while (<>)
{
if (/^-----BEGIN/ .. /^-----END/)
{
if (/^-----BEGIN/) { $first=$_; next; }
if (/^-----END/) { $last=$_; next; }
$out.=$_;
}
}
$out =~ s/\s//g;
$out =~ s/(.{128})/$1\n/g;
print "$first$out\n$last\n";__END__
QUESTION: Why do I get -
Use of uninitialized value in concatenation (.) or
string at sx.perl line 18, <> line 1680When executing this code with a 1,680 line input file?
BTW - There is in fact data on line 1,680 ...-Sx-
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>
