sub prog_replace_string { my ($replace_this, $with_this, $string) = @_; $string =~ s{\Q$replace_this\E}{$with_this}g; $string; }