Solution (source code)

= Solution

The labels (i) and (ii) in the original PDF are hypotheses of one theorem, not separate requests. Here is the finite-cover step furnished by the <compact> fibres. Start with any <open cover> $\{U_i\}_{i\in I}$ of $f^{-1}(K)$, with the $U_i$ open in $X$ (a relative cover can be lifted to one of this form). For each $y\in K$, <compactness> gives a finite set $I_y\subseteq I$ with
$$
f^{-1}(\{y\})\subseteq V_y:=\bigcup_{i\in I_y}U_i.
$$
An empty fibre needs no cover elements: take $I_y=\varnothing$ and $V_y=\varnothing$.

The complementary set $A_y=X\setminus V_y$ is <closed set>. By the <closed map> hypothesis, its image is <closed set>, so
$$
W_y:=Y\setminus f(A_y)
$$
is open, contains $y$, and satisfies $f^{-1}(W_y)\subseteq V_y$. These open sets cover the <compact set> $K$. Select finitely many, $W_{y_1},\ldots,W_{y_m}$. The finitely many original cover elements with indices in $I_{y_1}\cup\cdots\cup I_{y_m}$ then cover $f^{-1}(K)$. Therefore
$$
\boxed{f^{-1}(K)\text{ is compact}}.
$$
This proves the unheaded conclusion in the PDF as well as explaining the role of hypothesis (i). No <Hausdorff> assumption is needed for this <compact-preimage theorem for closed maps>.