Taken from Quora.com...
This sentence, among many others, plays on our association of parts of speech when we read the sentence: "The complex houses married and single soldiers and their families."
"Complex" is the noun as well as the main subject of the sentence. The sentence is about the complex. The first interpretation of "houses" is almost always as a noun, but here it is a verb, which means "accommodates". It is the same case with "married" which usually acts as a verb, is an adjective to the soldiers, which surprisingly comes after another adjective "single".
To sum it up, the sentence is trying to describe a complex (an apartment complex, perhaps) where both single as well as married soldiers and their families reside.
My question is: Is there a name for such sentences?
P.S. I would really enjoy reading a few more of the kind.