Solution (source code)

= Solution

The <open sets> $U$ and $X\setminus C_\lambda$ cover $X$. A finite subcover exists by <compactness>, and taking complements yields
$$
\boxed{\bigcap_{\lambda\in\Lambda_0}C_\lambda\subseteq U}
$$
for a finite index set. This is the <finite intersection characterization of compactness> in a neighborhood form; the finite index set may be empty when $U=X$.

The <Šura-Bura lemma> states that in a <compact Hausdorff space> the <connected component> $C(x)$ of a point equals its <quasi-component>, the <intersection> of all <clopen> neighborhoods of that point. It also follows that each component has a neighborhood basis of <clopen> sets. Here is a proof of both assertions.

Let $Q$ be the <intersection> of the <clopen> neighborhoods of $x$. Every <connected set> containing $x$ lies in each such neighborhood, so $C(x)\subseteq Q$. The set $Q$ is closed and <compact>. If $Q$ were disconnected, write it as the disjoint <union> of nonempty relatively <closed sets> $A,B$, choosing $x\in A$. Both are <compact> and closed in $X$. Normality gives disjoint <open sets> $O_A,O_B$ containing them. By the finite-intersection result, a finite <intersection> $V$ of <clopen> neighborhoods of $x$ satisfies $Q\subseteq V\subseteq O_A\cup O_B$. Then $V\cap O_A$ is <clopen> in $V$, hence <clopen> in $X$, and contains $x$ while excluding $B$. This contradicts the definition of $Q$. Thus $Q$ is <connected> and equals $C(x)$. Given any <open neighborhood> of the component, the same finite-intersection argument supplies a <clopen> neighborhood inside it. This proves the neighborhood-basis form as well.

For an explicit <noncompact counterexample to the Šura-Bura lemma>, put $p=(0,0)$, $q=(1,0)$, and $\varepsilon_m=1/(m+2)$ for $m\geq1$. Let $A_m$ be the polygonal arc with successive vertices
$$
(\varepsilon_m,0),\quad(\varepsilon_m,m),\quad(1-\varepsilon_m,m),\quad(1-\varepsilon_m,0),
$$
and give $Z=\{p,q\}\cup\bigcup_{m\geq1}A_m$ its <subspace topology> from the plane. The arcs are pairwise disjoint: a higher arc has its vertical sides outside the horizontal span of any lower arc. Each $A_m$ is <compact> and relatively open in $Z$, so is <clopen>. For relative openness, all sufficiently high arcs have vertical sides close to $x=0,1$ and horizontal sides above a fixed bounded neighborhood of $A_m$; the remaining finitely many <compact> disjoint arcs have positive distance from it.

A <connected> subset containing $p$ cannot meet any of these <clopen> arcs, so it lies in $\{p,q\}$ and is just $\{p\}$. But any <clopen> neighborhood of $p$ contains the left endpoints of all sufficiently high arcs. <Connectedness> of each arc forces the entire arc into that neighborhood, and closedness then forces the limit $q$ of their right endpoints into it. Conversely the <clopen> set $Z\setminus A_m$ excludes every point of $A_m$. Therefore
$$
\boxed{C_Z(p)=\{p\},\qquad Q_Z(p)=\{p,q\}.}
$$
The <compact> set containing the endpoints has lost the connection supplied by arcs escaping to arbitrarily large height; <compactness> of the ambient space is essential to the lemma.

Now let $D=\bigcap_n C_n$ for the decreasing <compact> <connected sets> in the <compact> <Hausdorff> setting. Every finite <intersection> is one of the nonempty $C_n$, so the <finite intersection property> gives $D\ne\varnothing$. It is closed and hence <compact>. If it were disconnected, its two nonempty <compact> pieces would have disjoint <open neighborhoods> $U,V$ in $X$. Since $D\subseteq U\cup V$, the initial finite-intersection result and the decreasing property give $C_N\subseteq U\cup V$ for some $N$. This set meets both neighborhoods because it contains $D$, contradicting its <connectedness>. Thus
$$
\boxed{D\text{ is nonempty, compact, and connected}.}
$$
The argument does not need <connectedness> of the whole ambient space.

For the requested failure without ambient <compactness>, add the central ray $L=\{(1/2,t):t\geq1\}$ to the previous example and put $X=Z\cup L$. For $n\geq1$ define
$$
\boxed{C_n=\{p,q\}\cup\bigcup_{m\geq n}A_m\cup\{(1/2,t):t\geq n\}.}
$$
Each graph formed by the displayed arcs and ray is <connected>: each arc meets the ray at its top. Adding $p,q$, which are limit points of the graph, preserves <connectedness> because the <closure> of a <connected set> is <connected>. Its relative <closure> in $X$ adds exactly these two points, so $C_n$ is closed in $X$. To check that no omitted point is a further limit, a bounded neighborhood away from the lines $x=0,1$ meets only finitely many arcs; the deleted initial arcs are disjoint <compact> sets, and the deleted ray segment lies strictly below the remaining ray. All other planar limit points on $x=0,1$ are outside $X$.

The sets are decreasing and nonempty, and $X=C_1$ is <connected> and <Hausdorff>. Every individual arc and every point of finite height on the ray disappears from sufficiently late sets. Consequently
$$
\boxed{\bigcap_{n\geq1}C_n=\{p,q\},}
$$
a nonempty <compact> disconnected set. Reindexing by $n+1$ gives the source's indexing by $\omega$. The graph is unbounded, so the ambient subspace is not <compact>. This is an explicit <decreasing closed connected sets with disconnected compact intersection> example.

\Image[/past-exam-of-the-analytic-topology-and-axiomatic-set-theory-course-of-the-university-of-oxford/2010-escaping-arcs.png]
{title=Arcs escaping to infinity: distinct components in the left space and connected tails in the right space}