Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: How do I replace certain character if condition exists

by kilinrax (Deacon)
on Apr 17, 2003 at 13:14 UTC ( [id://251185]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    abowley@krait:~$ (echo 'Madrid(Spain' && echo 'Madrid(Spain)') | perl 
    +-pe 's/\((?![^)]*\))/ /g;'
    Madrid Spain
    Madrid(Spain)
    
  2. or download this
    s/
      \(      # an open bracket
    ...
        \)    # followed by a bracket
      )
     / /gz;
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (3)
As of 2024-04-24 05:35 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found