in reply to Re^3: regex in REPLACEMENT in s///
in thread regex in REPLACEMENT in s///
Well, I saw it as an exercise in using a nested s///. If you don't, then you might as well use:
my $res = $str =~ s/\d/3/gr;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: regex in REPLACEMENT in s///
by tybalt89 (Monsignor) on Sep 14, 2023 at 12:52 UTC |