In this challenge, you are to code in any language a program or function that will take a string and replace certain characters within it with different characters.
The input is the same for both functions and full programs:
[string] [char1] [char2]
stringwill be an indefinite line of characters surrounded by quotation mars, such as "Hello, World!" or "1 plus 2 = 3".
char1will be a single character within
char2will be a single character not necessarily in
Your output will take
string and replace all instances of
char2, then output the result as
modified string. Case should be ignored, so the input
"yolO" o u should output
"Hello, World!" l r
"Slithery snakes slurp Smoothies through Silly Straws" s z
zlithery znakez zlurp zmoothiez through zilly ztrawz
"Grant Bowtie: Only the best future bass artist ever" : -
Grant Bowtie- Only the best future bass artist ever
"019 + 532 * 281 / ? = waht/?" / !
019 + 532 * 281 ! ? = waht!?
This is code golf, so the shortest answer (in bytes) at the end of the week (the 14th of September) wins. Also, anything not specified in this challenge is fair game, meaning that stuff I don't explain is up to you.