Program to reverse the order of words of a string in place (MIT Hacking a Google Interview, Handout #2)