in reply to Re: next if attempt
in thread next if attempt
To make it a bit easier to update, one might write it as:
my @stopwords = qw( longwordOne anotherLongWord thirdLongHere ); my $stopmatch = join( '|', @stopwords ); while( <DATA> ) { next if /$stopmatch/i; print; }
Thus you only have to update the @stopwords array to add another stop-word.
--
"To err is human, but to really foul things up you need a computer." --Paul Ehrlich
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: next if attempt
by particle (Vicar) on Jul 16, 2003 at 13:40 UTC | |
by Aristotle (Chancellor) on Jul 16, 2003 at 15:19 UTC | |
by hardburn (Abbot) on Jul 16, 2003 at 14:03 UTC | |
by particle (Vicar) on Jul 16, 2003 at 15:03 UTC |