added a new function, the function "replace"