Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: Regex Pipe Return

by LanX (Saint)
on Dec 27, 2012 at 01:34 UTC ( [id://1010436]=note: print w/replies, xml ) Need Help??


in reply to Regex Pipe Return

not sure what you want...

you want this:

$string =~ m/(A|B)(A|B)/; $match="$1$2";

or this:

$string =~ s/(A|B)(A|B)/lc("$1$2")/e;

or do you need $PREMATCH, $MATCH and $POSTMATCH ?

Cheers Rolf

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1010436]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (5)
As of 2024-04-24 11:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found