Solution (source code)

= Solution

A subset $B\subseteq\mathbb C$, with its <subspace topology>, is <compact> when every <open cover> of $B$ has a <finite subcover>. The <Heine-Borel theorem> in the <complex plane>, identified with $\mathbb R^2$, says
$$
\boxed{B\text{ compact}\iff B\text{ closed and bounded}.}
$$
Closedness is in the ambient <complex plane>. For a <continuous> real-valued function on a nonempty <compact> set, the <supremum> and <infimum> are finite and attained.