Pergunta de entrevista da empresa Amazon

Reverse the words in a string. Code it.