in reply to string substitution
You need the $1 and $2 to retain your symbols. update symbols between square brackets according to your wishes$newstring =~ s/([+<-/)*>])HELL([+<-/)*>])/$1BAD$2/g;
Cheers
Sam
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re (2) string substitution
by mandog (Curate) on Oct 08, 2003 at 17:07 UTC |