update reverse words in a string