I have been tasked with proving that with respect to the standard (usual) topology $T_{st}$, $[0,1]$ is not homeomorphic to $(0,1)$ using connectedness. My problem is that from my understanding, since both $[0,1],(0,1)\subseteq \mathbb{R}$ and are intervals they are both connected with respect to $T_{st}$. Is there some other way that I may use connectedness to prove this?
I had the idea of using the fact that the number of connected components is a topological invariant, however I do not see an equivalence relation that would split these two intervals into a different number of components.
Suppose there is a homeomorphism $f:[0,1] \to (0,1)$. Let $f(0)=a$. Let $g$ be the restriction of f to $(0,1]$. Then $g$ is a homeomorphism from $(0,1]$ onto $(0,1) \setminus \{a\}$. This is a contradiction because the domain of $g$ is connected and the range is not.