Show that $\{0,1\}^\mathbb{R}$ is separable. I was trying to think about how to show this. First I considered the subset $S=\{f \in\{0,1\}^\mathbb{R}:f(a)=0,a \in \mathbb{Q}^{c}\}$. However I was told that although this set is dense it is uncountable being of cardinality $2^{|\mathbb{N}|}$. I was given a hint to use the bijective correspondence with elements in this set, and elements in the power set of $\mathbb{R}$ and consider the collection of all finite subsets of $\mathbb{R}$. So in this case I should consider the subset $S=\{f\in\{0,1\}^\mathbb{R}:f(a)=0,\text{for all but finitely many }a\}$. This set is supposedly countable and dense.
Now I am rethinking this. I see the set of all finite subsets of $\mathbb{N}$ is countable, so maybe I was told to consider the set $S=\{f \in\{0,1\}^\mathbb{R}:f(a)=0 \ \text{for all but finitely many}\ a \in \mathbb{N}\}$? If I do this, to prove this subset is countable, would I just need to prove the equivalent statement that the set of all finite subsets of $\mathbb{N}$ is countable?
Once the set is proved to be countable, the next thing to prove is that the closure of the set is equal to $\{0,1\}^\mathbb{R}$. That the set is dense. I will try to give this an attempt.
Let $x \in \{0,1\}^{\mathbb{R}}$. Let $\prod U_{\alpha}$ be an open set containing $x$. Then $U_\alpha=\{0,1\}$ for all but finitely many $\alpha$. Now I am struggling to figure out what to do if $f(a)=1$ for only finitely many irrationals or non whole numbers. Maybe I should go back to considering the second set? The set of functions that are zero at each coordinate but finitely many? If this is the case then again Let $x \in \{0,1\}^{\mathbb{R}}$. Let $\prod U_{\alpha}$ be any open set containing $x$. The $U_\alpha=\{0,1\}$ for all but finitely many alpha. So certainly it contains a point in $S$ since it contains any function $0$ everywhere but finitely many coordinates. What would be a better way to show this?Is the set of all finite subsets of $\mathbb{R}$ actually countable?
Unfortunately I am hitting a brick wall with how to actually come up with all of the math I need to show this set is dense. How should I try to show any open set containing $x$ must contain some elements in $S$?