Let $X$ be a Set. For all Subsets $ A \subset X$ the characteristic function of A is defined as:
\begin{align} \chi_A(x)= \begin{cases} 1 \iff x \in A \\ 0 \iff x \notin A \end{cases} \end{align} Let $\lbrace0,1\rbrace^X$ be the Set of functions $ X \longrightarrow \lbrace 0,1\rbrace $. Further let $P(X)$ be the power set of $X$.
Show that the following function is a bijection: \begin{align} P(X) & \longrightarrow \lbrace 0,1\rbrace ^X \\ A & \longmapsto \chi_A \end{align} I have struggled with this problem for a few days now and I believe one of my biggest issues is to create the desired set $\lbrace0,1\rbrace^X$.