in reply to Doing "it" only once
Of course, if print is really something more, extract it to a subroutine.while ( <FH> ) { last if $_ eq 'foo'; # Where foo can only appear once in the file print; } while ( <FH> ) { print; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Doing "it" only once
by Limbic~Region (Chancellor) on Sep 21, 2005 at 15:31 UTC | |
by jdporter (Paladin) on Sep 21, 2005 at 15:47 UTC | |
by Limbic~Region (Chancellor) on Sep 21, 2005 at 16:29 UTC | |
by jdporter (Paladin) on Sep 21, 2005 at 18:01 UTC |