Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Balanced delimiter parsing

by I0 (Priest)
on Oct 06, 2002 at 06:43 UTC ( #203141=note: print w/ replies, xml ) Need Help??


in reply to Balanced delimiter parsing

Using only regexps

$_="...<value>...<value>...</value>...</value>..."; ($re=$_)=~s#((<value>)|(</value>)|.)#${[')','']}[!$3]\Q$1\E${['(','']} +[!$2]#gs; print join "\n",eval{/$re/}; die $@ if $@=~/unmatched/i;


Comment on Re: Balanced delimiter parsing
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (9)
As of 2015-07-05 20:51 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (68 votes), past polls