TITLE: Does there exist a compact metric space $X$ containing countably infinitely many clopen subsets?
QUESTION [5 upvotes]: From this Clopen subsets of a compact metric space we know that any compact metric space $X$ contains at most countably many clopen subsets ; my question is : Does there exist a compact metric space $X$ containing countably infinitely many clopen subsets ?

REPLY [7 votes]: Consider the subset of $\mathbb R$
$$\{ \frac{1}{n} | n\in \mathbb N^*\} \cup \{0\}\;$$ which inherits a metric structure from the standard metric of $\mathbb R$. The sets $\{1/n\}$ are countably infinitely many clopen subsets.

REPLY [2 votes]: The Cantor set is a standard example of such a space.
{"set_name": "stack_exchange", "score": 5, "question_id": 1790410}