Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: RegEx + vs. {1,}

by ELISHEVA (Prior)
on Oct 10, 2012 at 14:16 UTC ( [id://998232]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    print $x = "abcdefgxxabcdefgzzabcdsjfhkdfab", "\n";
    print  "<" . join('|',$x =~ /(\w{2,}?)(?=.*?\1)/g) , ">\n";
    
    #outputs: <ab|cd|ef|ab|cd|ab>
    

Log In?
Username:
Password:

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

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

    No recent polls found