I need to match a pattern something like this
$var="FILES CHECKED IN: TEST 1.3 5.4 S.txt 1.93 1.2 + ";chomp($var); my $pattern='FILES CHECKED IN:[\s]+(.*?)\s+(\d+\.\d+(\.*\d*)*)\s+(\d+\ +.\d+(\.*\d*)*|NONE)*';chomp($pattern); if ("$var" =~ m{$pattern}) { print "MATCH==$1==$2==$4==$6==$7==$8==$9 \n"; } else { print "NO=$1\n " ; }
output- MATCH==TEST==1.3==5.4========
This only matches the last pattern, i want it to match as many times its present. i.e means match repeatedly..can anyone help me in this?
In reply to Repeated Pattern Matching Fails by kapila
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |