TITLE: Every real function has a dense set on which its restriction is continuous
QUESTION [58 upvotes]: The title says it all: if $f\colon \mathbb{R} \to \mathbb{R}$ is any real function, there exists a dense subset $D$ of $\mathbb{R}$ such that $f|_D$ is continuous.
Or so I'm told, but this leaves me stumped.  Apart from the rather trivial fact that one can find a dense $D$ such that the graph of $f|_D$ has no isolated points (by a variant of Cantor-Bendixson), I don't know how to start.  Is this a well-known fact?

REPLY [48 votes]: It is a theorem due to Blumberg (New Properties of All Real Functions - Trans. AMS (1922)) and a topological space $X$ such that every real valued function admits a dense set on which it is continuous is sometimes called a Blumberg space.
Moreover, in Bredford & Goffman, Metric Spaces in which Blumberg's Theorem Holds, Proc. AMS (1960) you can find the proof that a metric space is Blumberg iff it's a Baire space.