TITLE: What is the set of all functions from $\{0, 1\}$ to $\mathbb{N}$ equinumerous to?
QUESTION [6 upvotes]: What is the set of all functions from $\{0, 1\}$ to $\mathbb{N}$ equinumerous to? I have figured out the question when it's the other way around, but I am not making any progress here. The worst thing is, I don't know how to think of such problems, and even when it was functions from $\mathbb{N}$ to $\{0, 1\}$, I would have never gotten it myself without help. When I think about this I think of the following: it's a function, so one thing can't be sent to two+ things, but two things can be sent to the same thing. So at least, we are mapping both 0 and 1 to the same element, and at most we are mapping it to two different elements. But that doesn't really give me anything... Thanks!

REPLY [10 votes]: The set of functions from $\{0,1\}$ to $\mathbb N$ (denoted by $A$ from here on end) can be seen as the set of all ordered pairs in $\mathbb N\times\mathbb N$.
Let us prove that:

Suppose $f\in A$, then $f(0)\in\mathbb N$ and $f(1)\in\mathbb N$, therefore the pair $\langle f(0),f(1)\rangle\in\mathbb N\times\mathbb N$, this means that this mapping is indeed well defined.
Suppose $f,g\in A$ two different functions, either $f(0)\neq g(0)$ or $f(1)\neq g(1)$. Either way $\langle f(0),f(1)\rangle\neq\langle g(0),g(1)\rangle$, we also have that this mapping is injective (sends two different elements to different results).
Suppose $\langle a,b\rangle\in\mathbb N\times\mathbb N$, define $f\in A$ as $f(0)=a, f(1)=b$ then $f$ is mapped to $\langle a,b\rangle$, therefore the mapping is onto $\mathbb N\times\mathbb N$.

All in all we have the mapping is a bijection, so it is enough to understand what is the size of $\mathbb N\times\mathbb N$.
The cardinality of this collection is indeed $\aleph_0$. There are two common ways to show that:

Cantor's pairing function, $\langle a,b\rangle\mapsto \frac{(a+b)(a+b+1)}{2}+a$, and show it is indeed a bijection.
Cantor-Bernstein's theorem, we find injections from $\mathbb N$ into $\mathbb N\times\mathbb N$ and vice-versa. Clearly $\mathbb N$ is not of larger cardinality (by $n\mapsto \langle 0,n\rangle$ which is clearly injective), on the other hand $\langle a,b\rangle\mapsto 2^a3^b$ is also an injective mapping, implying $|\mathbb N\times\mathbb N|\le|\mathbb N|$, and therefore $\mathbb N$ and $\mathbb N\times\mathbb N$ have the same cardinality.

REPLY [7 votes]: HINT $\rm\quad\ \ |Maps(\{0,1\},\mathbb N)| \le |\mathbb N|\ $ since $\rm\ f\:\mapsto\: 2^{\:f(0)}\ 3^{\:f(1)}\ $ is injective (one-to-one). 
Reversely $\rm\:|Maps(\{0,1\},\mathbb N)| \ge |\mathbb N|\:$ as it includes the $\rm\:|\mathbb N|\:$ constant maps $\rm\:f_{\:n}\:$ mapping$\rm\ 0,1\:$ to $\rm\:n\:.$