Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Elegant examples to parse parenthesised strings

by Krambambuli (Deacon)
on May 19, 2010 at 12:48 UTC ( #840686=note: print w/ replies, xml ) Need Help??


in reply to Elegant examples to parse parenthesised strings

If, as it seems, you need only the innermost parenthesises, something like

my @exps = $text =~ / \( ( [^\(]*? ) \) /xmg;
might be good enough for this particular situation.


Krambambuli
---


Comment on Re: Elegant examples to parse parenthesised strings
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (10)
As of 2014-07-25 12:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (171 votes), past polls