Cardinality of a certain functions collection

25 Views Asked by At

I'm interested to calculate the cardinality of the following set,

$$S = \left\{ f \in \mathbb{N}^{\mathbb{N}} \mid f \circ f = \mathrm{id}\right\}$$

I've noticed that $ f \in S \iff \forall n, m \in \mathbb{N} : [f(n) = m \iff f(m) = n]$.
Assuming this is indeed correct and intuitively speaking, it seems to "behave" as $|S| = |\aleph| $. The difficulty I'm experiencing takes place when I try to figure out the required bijection and formalize it.

Wish to get some help, thanks.