in reply to extracting lines from a string - while ignoring the \n character

Hi,
would this help you?
## single quotes around heredoc my $string = <<'STRING'; one. two \n \n . three. STRING my @lines = $string =~ m/^(.*?)$/msg; print scalar @lines, " lines\n";
results in: 3 lines
Regards,
svenXY