I know this sounds like harping, but it is meant in good faith: For this exercise to be meaningful we need to stay clear of built-in functions and write an algorithm to do this task using only what we've be taught up to this point. By my recollection,
str.replace() is not covered in the previous units to this one so we should not be using it.
That is not to say don't learn about it on your own, just don't use it for this exercise, as the only submission. Write it as many ways as you can, for the practice and added learning that comes with it. This can be done without extra help from Python's library.
An earlier topic on this subject arose in which I basically say the same thing, so just ignore that part. There are a couple of examples using the built-ins as well as a little discussion (one-sided, mind) on usage.