If you have undef $/
@arr = split /\n/, $line; map {s/^\n+//;} @arr; $"="\n"; print "@arr"
if you are using while without undef $/, try the following
the above codes not tested, try it out if it helps youwhile ($line = <FILE>) { $line =~ s/^\n+//; }
Prasad
In reply to Re: regexp for blank lines
by prasadbabu
in thread regexp for blank lines
by cspears
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |