Extreme value theorem, without Heine Borel. I was wondering, if there are any mistakes, in this proof of the extreme value theorem:
Theorem. Let $X$ be a compact set and $f:X\rightarrow\mathbb{R}$, s.t. $f$ is continuous. Then there exists $x\in X$, s.t. for all $y\in X$, $f(y)\leq f(x)$.
Proof. Let $\epsilon>0$, $x\in X$ and $U_x=f^{-1}(-\infty,f(x)+\epsilon)$. As $f$ is continuous, $U_x$ is open. Also, $x\in U_x$. Then $\{U_x\}_{x\in X}$ is an open cover of $X$. As $X$ is compact, there exists $x_1,\dots,x_n\in X$, s.t. that $\{U_{x_k}\}_{1\leq k\leq n}$ is an open cover of $X$.
Let $1\leq m\leq n$, such that $f(x_m)=\max_{1\leq k\leq n}f(x_k)$ and $y\in X$. Then, there exists $1\leq k\leq n$, s.t. that $y\in U_{x_k}$. Then $f(y)<f(x_k)+\epsilon\leq f(x_m)+\epsilon$. As $\epsilon$ was arbitrary, $f(y)\leq f(x_m)$.
Somehow, I am sceptic about this proof, as it seems too simple. Any thoughts?
 A: This might be fixable, depending exactly what sort of thing $X$ is. For $\epsilon>0$, say a point $x\in X$ is $\epsilon$-maximal if $\forall y\in X$, $f(x)+\epsilon>f(y)$.
Your arugment shows that we can find, for each $\epsilon>0$, a point $x_\epsilon$ which is $\epsilon$-maximal.
Now argue as follows: consider the sequence $x_{1\over n}$ for $n\in\mathbb{N}_{>0}$. By (sequential) compactness of $X$, this has a convergent subsequence $\mathcal{S}=\{x_{s_n}\}$ - say, converging to $z$. 
Now fix $\epsilon>0$. By continuity of $f$, we can find a $\delta>0$ such that, for $\vert y-z\vert<\delta$, we have $\vert f(y)-f(z)\vert<\epsilon$. But since $\mathcal{S}\rightarrow z$, there is some $x_{s_n}$ within $\delta$ of $z$, with $s_n<\epsilon$; so $f(z)$ is within $\epsilon$ of an $\epsilon$-maximal value, and hence $z$ is $2\epsilon$-maximal.
So $z$ is $\epsilon$-maximal for all $\epsilon>0$, and hence maximal; done.

Note that I need $X$ to be sequentially compact. This is a consequence of compactness for metric spaces, but not for topological spaces (see What's going on with "compact implies sequentially compact"?), so this argument isn't fully general.
A: @DanielFischer has answered the question in a comment: you have not constructed a single $x \in X$ as required, but rather a different one (as far as we know) for each $\epsilon$.  So the proof doesn't work, sorry.
