As Bobby says, an automated way of detecting this would be unreliable at best and a hindrance to asking questions (something we don't want) at worst.
However, you may be onto something. Currently there is a page with information on how to ask a good question. It seems to me that this page could potentially be expanded with more helpful information, including examples of bad questions vs. good questions.
It seems to me that the How To Ask page can use a lot more attention anyway (and be more prominently linked from the Ask Question page). For a while now, the canonical page to which people link for advice on asking questions has been on an external blog. While that blog post is an excellent discussion of the subject, in my opinion it should be the aim of Stack Overflow to internalize canonical content. (A goal often cited in the definition of poor questions and answers.) And, given the long standing relationship between the blog's owner and Stack Overflow, I doubt anybody would mind if a re-vamped How To Ask page included a link to the blog post as "official" further reading on the subject.