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

Re: A complex recursive regex,help

by Enlil (Parson)
on Feb 06, 2003 at 00:59 UTC ( #233010=note: print w/replies, xml ) Need Help??


in reply to A complex recursive regex,help

TMTOWTDI
my $a = "x|xx|xx|xxxx|xx|xxx|xx|xx|x"; 1 while ($a =~ s/\|xx\|/|x x|/); print "[$a]\n"; __DATA__ [x|x x|x x|xxxx|x x|xxx|x x|x x|x]

but as tachyon mentioned: what to do with the edge cases? (this method is not optimal by any means.)

-enlil

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (10)
As of 2018-10-22 12:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    When I need money for a bigger acquisition, I usually ...














    Results (119 votes). Check out past polls.

    Notices?
    • (Sep 10, 2018 at 22:53 UTC) Welcome new users!