Surjection iff Right Inverse/Non-Uniqueness/Examples/Arbitrary Example

Example of Surjection iff Right Inverse: Non-Uniqueness
Let $S = \set {0, 1}$.

Let $T = \set a$.

Let $f: S \to T$ be defined as:
 * $\forall x \in S: \map f x = a$

Then $f$ has $2$ distinct right inverses.

Proof
Let $g_0: T \to S$ and $g_1: T \to S$ be the mappings defined as:

We have that:


 * $\Dom {g_0} = \Cdm f = \Dom {g_1}$

and that $f$ is a surjection.

Hence we can construct:

and:

Hence both $g_0$ and $g_1$ are distinct right inverses of $f$.