reverse string of given words