if you are using the /g modifier in your regex, you can use pos($string) to get the position after the match.
see perlvarmy $s = "ABCDFEFFAA"; $s =~ m/AA/; say "$-[0] $+[0]"; __END__ 8 10
In reply to Re: Identifying the position of match using regular expressions
by tinita
in thread Identifying the position of match using regular expressions
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |