I'm trying to write down and prove that a map defines an injection from $f: (0,1)^2 \to (0,1)$. Here is my attempt.
We define $f: (0,1)^2 \to (0,1)$ as follows. Given $x,y \in (0,1)$ with decimals expansions $x = \sum\limits_{i=1}^{\infty} \frac{a_i}{10^i}$ and $y = \sum\limits_{i=1}^{\infty} \frac{b_i}{10^i}$ that don't terminate in a string of $9$'s, define $$ f(x,y) = \sum\limits_{i=1}^{\infty} \frac{a_i}{10^{2i-1}} + \sum\limits_{i=1}^{\infty} \frac{b_i}{10^{2i}}. $$ Notice that because $x,y \neq 0$, it is not the case that $a_i, b_i = 0$ for all $i$, so $f(x,y) \neq 0$. Furthermore, the coefficient of $10^1$ is $0$, so $f(x,y) \neq 1$, by construction. Therefore, $f(x,y) \in (0,1)$, so $f$ is well-defined. I claim that $f$ is an injection. Suppose that $f(x,y) = f(x',y')$ for $(x,y), (x',y') \in (0,1)^2$, and write $$ x = \sum\limits_{i=1}^{\infty} \frac{a_i}{10^i}, \; x' = \sum\limits_{i=1}^{\infty} \frac{a_i'}{10^i}, \; y = \sum\limits_{i=1}^{\infty} \frac{b_i}{10^i}, \; y' = y = \sum\limits_{i=1}^{\infty} \frac{b_i'}{10^i}, $$ where we require that each of these decimal expansions doesn't terminate in $9$'s. Then, by the definition of $f$, we have $$ \sum\limits_{i=1}^{\infty} \frac{a_i}{10^{2i-1}} + \sum\limits_{i=1}^{\infty} \frac{b_i}{10^{2i}} = \sum\limits_{i=1}^{\infty} \frac{a_i'}{10^{2i-1}} + \sum\limits_{i=1}^{\infty} \frac{b_i'}{10^{2i}}. $$ Equating the coefficients of $10^{-k}$ for each $k \geq 1$, we find that that for every $k$, $a_k = a_k'$ and $b_k = b_k'$, so $x = x'$ and $y = y'$, so $(x,y) = (x',y')$.
How does this look? Is it missing detail? I worry that I could've made a jump in the final step, though if I wrote out the decimal expansions explicitly, it would be clear, since I disallowed terminating in $9$'s and therefore know that the decimal expansions are unique, I can recover the arguments of the function directly.