Show that the function $f: \mathbb{N}\to \{0,1\}^\mathbb{N}$ is not surjective

elementary-set-theory

I am having trouble showing that the function $f: \mathbb{N}\to \{0,1\}^\mathbb{N}$ is not surjective. I suppose that I have to show is that $\exists g\in \{0,1\}^\mathbb{N},\forall n\in\mathbb{N},g\neq g(n)$. However, I can't think of a way to show that $g\neq g(n)$. I know that I am supposed to use the Cantor's diagonal argument. Could you give me a hint towards the proof?

Best Answer

The trick in the diagonal argument is to make sure $g$ is different from each of the $f(n)$s by constructing it such that $g(n)\ne (f(n))(n)$. Since this is the only constraint on $g(n)$ it is very easy to find a possible $g(n)$ that does not equal $f(n)(n)$ ...