Meaning: If you ask someone what they are playing at, it means you are surprised by or unhappy about their behaviour. Although you seem to be asking a question, you do not always expect an answer!
Grammar: Here, this phrasal verb is used in a question structure as an exclamation. It cannot be separated from its particle.
What is he playing at?
What is he playing at, spending so much money?
What is he playing spending so much money at?
Example sentence: I don't know what they are playing at, losing all of those computer files.
Synonyms: get up to, think of