Now what if I'm trying to change just parts of a word? Like "Car" to "cah", or vise versa in "Martha" to "Marther". In the second case, if I just did an if like this:
<if sentance.include? "er"
user_input.gsub!(/er/, "a")
end >
It would take all "a"'s in "MArthA", which is not what I want.
Any ideas? For other examples. Replace words in string - ruby