in reply to regex related...search and delete
bla ...
depending on your textfile this can be indefinitely complex.
are parens ever nested?
is it always (L \d+ W \d+)?
If it's not a fix format I would try to match every parens-pair, and call a function with the match with /e modifier. s/\(.*?\)/kill_LW($&)/ge
- Ron
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: regex related...search and delete
by freekngeek (Acolyte) on Jan 14, 2013 at 10:43 UTC | |
by LanX (Saint) on Jan 14, 2013 at 10:53 UTC |
In Section
Seekers of Perl Wisdom