In a comment, John Lawler wrote:
(1) What to do? is not a sentence; there's no subject, for one thing. (2) The construction is not particularly archaic, although wh-infinitives have been around for a long time. They're still widely used. What they are isn't so much archaic or formal as it is formulaic. That is, everything is taken for granted and/or given in the context, so out of context they make no sense.
It may not be immediately clear to everyone why John said that there’s no subject in What to do?. I imagine some people are thinking that the wh- word there is the subject, but it’s not. It’s actually the object of that infinitive clause. Imagine a book title like Whom to call? There it’s clearly acting as the object of the verb call. If the answer is him.
- I don't know whom to call.
- Whom to call?
- Him.
- I’ll call him.
So it’s an object there.
That’s not to say that infinitive clauses cannot have subjects; they can do so, but this is not one of those cases. Examples of infinitive clause with an actual subject is:
- For her to call him that night was all he had ever hoped for.
- I need her to call me.
Just as not all sentences are questions, not all questions are sentences. That doesn’t make them ungrammatical. They simply aren’t sentences, since all sentences have a subject and a finite verb. When you have a wh- word plus an infinitive ending in an utterance ending with a question mark, you have a question. Any utterance that ends with a question mark is a question: it’s one inviting an answer. And not all answers are sentences either. They’re still answers.
Question: Ready?
Answer: Ready.