Suppose that F is a function from A to B ,where A and B are finite sets with |A| =|B|. Show that f is one to one if and only if it is onto.
I want to know my proof is right or wrong?
Proof: by contradiction
f[A] is image of function f.
Let f is one to one but not onto.
f is one to one = |f[A]| = |A| and
because its not onto (these exist some x other than f[A])
∃x (x∉ f[A] and x∈B) $\rightarrow$ |B|>|f[A]|
so, |B|> |A| (which contradicts |A|=|B|)
So f is onto.
Let f is onto but not one to one
f is onto = |f[A]| = |B| and
not one to one : |B| < |A| (which contradicts |A|=|B|)
so f is one to one