in reply to
Grepping with Perl: How to stop after first match?
Use
last
inside your loop.
Comment on
Re: Grepping with Perl: How to stop after first match?
In Section
Seekers of Perl Wisdom