in reply to Print all lines in a file except the last two
Assuming a CR after each line:
1 2 3 4 1234567890123456789012345678901234567890123456789 perl -e 'open(F,'f');@f=<F>;pop@f;pop@f;print"$_"foreach@f'
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Re: Print all lines in a file except the last two
by hardburn (Abbot) on May 20, 2004 at 16:41 UTC | |
Re: Re: Print all lines in a file except the last two
by Jasper (Chaplain) on May 20, 2004 at 15:50 UTC |
In Section
Seekers of Perl Wisdom