Hi barryscott
This may also help you in addition to j1n3l0
use strict; my @typedefs = qw(do re me fa so la ti do); while (my $line = <DATA>) { chomp($line); if(grep/$line/, @typedefs){ print "$line\n"; ## perform various actions here if line match } } __DATA__ do me a favour will you
Punitha
In reply to Re: line by line match on an array of strings
by Punitha
in thread line by line match on an array of strings
by barryscott
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |