use warnings; use strict; my $str = "This is a string which has bi-weekly data"; if ($str =~ /(\w+)[- ](daily|month|days|weekly|week)/) { my $found= $1; print "$found $2\n"; } __END__ bi weekly
In reply to Re: Group matching - Extracting what matches
by toolic
in thread Group matching - Extracting what matches
by madbee
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |