TITLE: Formally show that the set of continuous functions is not measurable
QUESTION [8 upvotes]: Let $C(\mathbb{R})=\{ f:\mathbb{R}\to \mathbb{R} \colon \ f \text{ continuous}\}\subseteq \mathbb{R}^{\mathbb{R}} $.
How to prove formally that $C(\mathbb{R}) \notin \mathcal{B}(\mathbb{R}^{\mathbb{R}})$ (the product sigma algebra)?
The classic proof said that   $A \in \mathcal{B}(\mathbb{R}^{\mathbb{R}})$ iff exists $J\subseteq \mathbb{R}$ with $|J|\leq \aleph_0$ and $B\in \mathcal{B}(\mathbb{R^J})$ such that $A=B \times \mathbb{R}^{\mathbb{R}\setminus J}=\{f \in \mathbb{R}^\mathbb{R} \colon  \ (f(j) \colon \ t \in J) \in B\}$. In simpler terms,  $A$ only can have countable restrictions but the set of continuous functions have uncountable restrictions since every function on $C(\mathbb{R})$ needs to be continuous in every point $x \in \mathbb{R}$.
The last part of this proof always didn't satisfied me at all, and I don't really know how to do this proof formally. 
Any help or references will be appreciated.

REPLY [11 votes]: Here's a direct argument following tomasz's suggestion.  Let's take as given your characterization of the measurable sets $\mathcal{B}(\mathbb{R}^\mathbb{R})$.
Let $A \in \mathcal{B}(\mathbb{R}^\mathbb{R})$ be arbitrary.  We will show $A \ne C(\mathbb{R})$.  If $A = \emptyset$ we are done.  Otherwise, suppose $f \in A$.  If $f$ is not continuous, we are done.  Otherwise, suppose $f$ is continuous.  We know $A$ is of the form $A = B \times \mathbb{R}^{\mathbb{R} \setminus J}$, where $B \subset \mathbb{R}^J$ and $J$ is at most countable.  Since $\mathbb{R}$ is uncountable, $\mathbb{R} \setminus J$ is nonempty, so let $y \in \mathbb{R} \setminus J$.  Define $g$ by $g(y) = f(y)+1$ and $g(x) = f(x)$ for $x \ne y$.  Then $g \in A$, but $g$ is certainly not continuous.