# Conditions on $X$ ensuring that a non-constant continuous function $f: X\to \mathbb{C}$ exists

Let $X$ be a compact Hausdorff space. I would like to find a (minimal) condition on $X$, which is sufficient to guarantee that one can always find a non-constant continuous function

$f : X \to \mathbb{C}$.

Clearly we need to assume that $|X|>1$, but what else can we say?

-
Urysohn's lemma says that $\vert X \vert > 1$ suffices. –  Andrea Nov 19 '11 at 13:40

As has been pointed out in the comments, $|X|>1$ is both necessary and sufficient: if $x,y\in X$ are distinct, Urysohn’s lemma ensures that there is a continuous function $f:X\to[0,1]$ such that $f(x)=0$ and $f(y)=1$.