Doubt in my proof (basic topology) The exercise was to prove there exists no surjection from a connected space to $S^0$. I'm not particularly satisfied with the end of my proof though, and worse, I'm sure it's a rather stupid question! Here's what I did;
Let $T$ be a connected topological space. Take $f: T \mapsto S^0$, and suppose $f$ is continuous and surjective.
For $f$ to be continuous, we must ensure the preimages of any open subset of the image are themselves always open. Since $f$ continuous, we shall call the open sets $f^{-1}(\{+1\}) = U$ and $f^{-1}(\{-1\}) = V$, where $U \cap V = \emptyset$, and $U,V \not= \emptyset$ so as to satisfy the definition of $f$.
Now since $T$ is connected, we cannot have $U \cup V = T$, [dodge part I'm not happy with:] so there are points in $T$ for which $f$ is not defined, contradicting the fact that $f$ is surjective*, therefore if $f$ is to be continuous it cannot be surjective.
*does it? I thought it did at the time but.. I'm not 100% sure, and would like an explanation if it does, or what I should be saying if it doesn't. Thanks!
 A: You started off well.
It is true that $U \cup V = T$ and since $T$ is connected and $U$ and $V$ are both non-empty and open, this is a contradiction to the connectedness of $T$.
A: As the commenters, and Vishal in his answer, have said, you began well but lost sight of exactly what you were trying to show towards the end. Here's a full proof which begins with the bits you got correct (with a few edits to make it more succinct).
Let $T$ be a connected topological space. Suppose there exists a continuous surjective map $f: T \mapsto S^0$.
For $f$ to be continuous, we must ensure the preimages of any open subset of the codomain are themselves always open. The subset $\{+1\}$ is open in $S^0$ and has non-empty preimage $U=f^{-1}(\{+1\})$ by surjectivity. Similarly, there is a non empty $V$ such that $f^{-1}(\{-1\})=V$.
Clearly if $x$ is in $T$ then $x$ is in $U$ or $V$ as $f(x)$ is either $+1$ or $-1$. Also, $x$ can not be in both $U$ and $V$ as this would imply that $f(x)=1$ and $f(x)=-1$, hence $U\cap V=\emptyset$. It follows that $U$ and $V$ are non-empty open subset of $T$ such that $U\cap V=\emptyset$ and $U\cup V=T$. This contradicts the fact that $T$ is a connected space and so such an $f$ can not exist.
