4 ms·
Since Perl 5.14, it could be simplified to $data = "foobarfoo" say $data =~ s/bar/baz/gr say is like print, but adds a newline as well. The /r option doe
by arunix 7y ago
Since Perl 5.14, it could be simplified to
$data = "foobarfoo"
say $data =~ s/bar/baz/gr
say is like print, but adds a newline as well.
The /r option does a non destructive replace and returns the result.