pdotcdot has asked for the wisdom of the Perl Monks concerning the following question:
I would like to create a third variable based on the regex match generated above (ie the $var2 with the matched character a-z concatanated to the end). i suspect there is an easy answer but my brain is refusing to play ball. Thanks in advance, your servant pdotcodt.elsif($var1=~/[$var2][a-z]{1}/{ #stuff; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: returning variable from within regex
by tcf22 (Priest) on Aug 29, 2003 at 18:34 UTC | |
by diotalevi (Canon) on Aug 29, 2003 at 19:15 UTC | |
|
Re: returning variable from within regex
by roju (Friar) on Aug 29, 2003 at 19:34 UTC | |
|
Re: returning variable from within regex
by pdotcdot (Acolyte) on Aug 29, 2003 at 19:46 UTC | |
|
Re: returning variable from within regex
by Fletch (Bishop) on Aug 29, 2003 at 18:38 UTC | |
|
Re: returning variable from within regex
by pdotcdot (Acolyte) on Aug 29, 2003 at 19:15 UTC |