I was reading this post compact set always contains its supremum and infimum
There was an answer reposted as follows:
As $K$ is compact, we have that $K$ is bounded. So $\sup K$ and $\inf K$ exists. By definition $\sup K$, for every $n \in N$ exists $x_n \in K$ such that $\sup K- x_n<1/n$ then $\sup K = \lim x_n$ with $x_n \in K$, as K is closed follows that $\sup K \in K$. To inf is analogous. Ps: Compact ⇒ closed and bounded.
This proof is quite attractive but I do not get the idea that just because $\sup K$ exists, therefore there exists a sequence approaching it.
Can someone please explain this part to clarify why that $\sup K$ must exist for a compact set $K$?