In addition to the answer that directly addresses the question I would like to add that on Stack Exchange it is actually ideal if a question is output on hold as quickly as possible. This givegives the OP and the community the opportunity to address any issues with the content or handle discussions of on-topicness before reopening the question.
On Stack Exchange once an answer has been posted, and especially if the answer gets upvoted, options become more limited. OP no longer has unilateral say over their content. Extremely poor quality questions are less likely to be deleted. And edits to improve the quality can be invalidatinginvalidate answers, which can be a huge headache (and rejected.)
So when in doubt, output the question on hold, clear things up, get the question opened, then post your answer. If the community is trying to close a question but you want it open so you can answer it, work with the OP to make the question fit.