Searching for a number, followed by a char, followed by the same number is easy:
m/(\d).\1/
That also matches 111:
$ perl -E 'say "match" if "111"=~/(\d).\1/' match $
Alexander
In reply to Re: arithmetic in a regex ?
by afoken
in thread arithmetic in a regex ?
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |