Egen Interview Question

Technical phone interview a couple of knowledge based questions about javascript and other languages (difference between == and === in js). Next was a coding challenge: Reverse the words in string but keep the spaces where they are. ie: "Hi how are you?" -> "you? are how Hi"