The question is not hard if you are allowed to use extra memory: just tokenize into words, put them into array and reverse, then join them back into a new string.
It is harder to do it in place. I actually did not believe it was possible until looking up the answer on StackExchange. That solution involves a "trick" which one might not figure out under pressure.