in reply to Between START .. END

The value returned by scalar ".." is the sequential count, with "E0" tacked on the final line. So, just save it and use it:
while (<file>) { next unless my $where = /START/ .. /END/; print unless $where == 1 or $where =~ /E0/; }

-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.

Replies are listed 'Best First'.
Re^2: Between START .. END
by darrengan (Sexton) on Sep 14, 2005 at 02:22 UTC
    Hie Merlyn,
    That reply was quick!
    Tested the code and it works fine...
    Cheers to u!

    Florist In Malaysia