It may be that this is what you are after:
'abc12345' =~ /(\d+)$/; print $+[1] - $-[1];
Prints:
5
In reply to Re: Length of first captured match
by GrandFather
in thread Length of first captured match
by QM
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |