I'd like to know if the following proof is correct.
Prove that for every bijection $f : S \to S$, there exists a function $g : S \to S$ such that $f \circ g = i$ and $g \circ f = i$
proof: Let $f$ be a bijection from $S$ onto $S$, and let $i:S \to S$ be defined as $i(x)=x$ for any $x \in S$. By definition, each $y \in S$ is mapped to by exactly one element in $S$. Then let $g: S \to S$ be defined as $g(x_{0}) = z_{0}$ and $g(y_{0})=x_{0}$, where $f(x_{0})=y_{0}$ and $f(z_{0})=x_{0}$. It follows that
$i(x_{0})=x_{0}=g(y_{0})=g(f(x_{0}))=(g \circ f)(x_{0})$
and
$i(x_{0})=x_{0}=f(z_{0})=f(g(x_{0})) = (f \circ g)(x_{0})$