# Subset and bijection implies cardinal equality?

I hope I have not hereby created a duplicate, please perdon me if I did, but I had this question for a while now:

Let $$A \& B$$ be two sets such that $$A \subseteq B$$. Suppose there exist a one to one (bijective) function $$f : A \to B$$. Then have we got $$|A| = |B|$$?

I know that if these sets are finite, it works, but what about the infinite case

Thank you

T. D

• What you've written is false, but if you change $A=B$ to $|A|=|B|$, it is true. It is also true for the infinite case by the definition of cardinality. – Kevin Long Nov 18 '19 at 19:15
• That is what I meant, – T.D. Nov 18 '19 at 19:16
• It's always true that if there is a bijection $A \to B$ then $|A| = |B|$, regardless of whether $A$ is a subset of $B$. – Clive Newstead Nov 18 '19 at 19:30

Let $$A = 2\mathbb{Z}$$ (ie the even integers) and $$B = \mathbb{Z}$$. Then, $$A \subseteq B$$, and there is a bijection between them, (namely $$f:B \to A$$ defined by $$f(x) = 2x$$) but the sets are not equal