in the devil

expression, usually following a question word, emphasizes the uncertainty of a question

“Usually on the Saturday night, you know, there was a band from town. What in the devil was their name?”

“A telemarketer. How in the devil do you get rid of them?”