/^\w+\)/ extracts a letter followed by a closing bracket
\w also matches digits.
$ perl -E 'say $1 if q{ab1d2f} =~ m{^(\w+)$};' ab1d2f $
Cheers,
JohnGG
In reply to Re^2: regular expression
by johngg
in thread regular expression
by Mjpaddy
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |