Beefy Boxes and Bandwidth Generously Provided by pair Networks Bob
Perl Monk, Perl Meditation
 
PerlMonks  

Re: Variable-width negative lookbehind

by delirium (Chaplain)
on May 05, 2004 at 17:09 UTC ( #350844=note: print w/ replies, xml ) Need Help??


in reply to Variable-width negative lookbehind

How about the lovely and talented /e?

$string =~ s/(.)X+/$1 eq 'Y' ? YX : $1/eg;


Comment on Re: Variable-width negative lookbehind
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (11)
As of 2013-05-22 10:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best material for plates (tableware) is:









    Results (457 votes), past polls