Problem: Prove that the following sets are not homeomorphic. \begin{gather*} \begin{aligned} A & = \left\{ (x,y) \in \mathbb{R} ^2 : x = 2y + 1 \right\} \\ B & = \left\{ (x,y) \in \mathbb{R} ^2 : xy = 0 \right\}. \end{aligned} \end{gather*}
Solution: We recall that two spaces $X$ and $Y$ are homeomorphic then they have the same number of connected components. That is homeomorphism preserves connected components because it preserves the connectedness.
Let $f:A \to B$ be a homeomorphism. Look at figure below, they represent the two spaces $A$ and $B$.
If we remove one point from $A$, say $p$, and $f(p)$ from $B$, then still $f$ will be a homeomorphism. Note that $A \setminus \{ p \} $ and $B \setminus \{ f(p) \} $ can not be a homeomorphism as the number of connected components in both are different.