Figure of Speech
Chiasmus
From Greek chi (X) — the crossing letter. Distinguished from antimetabole (exact word repetition); a key device in classical oratory and biblical poetry.
Definition
A rhetorical figure in which the grammatical structures of two successive clauses are reversed (A-B / B-A).
Example
'Ask not what your country can do for you; ask what you can do for your country.' (JFK, 1961)