in reply to Re: specific numbers of digits
in thread specific numbers of digits
That will still match 6 digits, it'll just match the last 5 rather than the first 5. To match only 5 digits you need an assertion at both ends:
Hugom{ (?>! \d) # not after a digit \d(5} (?! \d) # not before a digit }x;
|
|---|