General Topology – How to Prove a Topological Space is Connected if it Has Exactly Two Clopen Subsets

connectednessgeneral-topology

The question is in the title, I'll rephrase it slightly here.

I am wondering how to prove that a topological space $X$ is connected if and only if it has exactly two clopen (closed and open) subsets.

Apart from writing down the definitions of connected, open and closed I really have no idea how to prove this. Any suggestions?

Best Answer

$(\Leftarrow)$: Considering the contrapositive... Let $X$ be a disconnected topological space. That is to say, there exist non-empty open subsets $U$, $V \subset X$ such that $U \cap V = \emptyset $ and $U \cup V=X$. Here $U$ and $V$ are clopen subsets of $X$ since $U^c=V$ and $V^c=U$.

$(\Rightarrow)$: Suppose now that $X$ is connected. Then there exist two clopen subsets of $X$, namely $\emptyset$ and $X$ itself. Here, recall that $\emptyset$ and $X$ are clopen by definition.