Synopsys Interview Question

Reverse the words inside a string.