Is there a function that is contiunous at all the rationals, and discontinuous at all the irrationals? [duplicate]

Possible Duplicate:
Set of continuity points of a real function

Motivated by the examples of the Dirichlet's no-where continuous function and Thomae's function, we know that a function can have discontinuities at the reals, or at the rationals. My question is whether the set of discontinuities can actually be at the irrationals only. Froda's theorem tells us that such a function cannot be monotone, so that cuts down on the search. Are there other obstructions? Can we exhibit such a function?

-

marked as duplicate by Jason DeVito, mt_, Thomas Andrews, Davide Giraudo, Zhen LinNov 9 '12 at 14:09

The set of points of continuity of a function is a countable intersection of open sets. $\Bbb Q$ is not such a set. – Davide Giraudo Nov 9 '12 at 13:47
Yes, I should have searched harder. Thanks all for the answers. – Apprentice Nov 9 '12 at 14:04

A natural followup question one might ask is if there is a function which is continuous on the rational numbers and discontinuous on the irrational numbers. This turns out to be impossible; the set of discontinuities of any function must be an $F_\sigma$ set. If such a function existed, then the irrationals would be an $F_\sigma$ set and hence, as they don't contain an interval, would also be a meager set. It would follow that the real numbers, being a union of the irrationals and the rationals (which is evidently meager), would also be a meager set. This would contradict the Baire category theorem.

-