show that a subset of $\mathbb{R}$ is compact iff it is closed and bounded 
Show that a subset of $\mathbb{R}$ is compact iff it is closed and bounded.

By definition of compact, a set $S\subset\mathbb{R}$ is compact if every open covering of $S$ has a finite subcovering. So for a given open covering {$U_{n}$}, there exista a finite covering $U_1,...,U_n$ of {$U_{n}$} s.t. $S\subset U_1\cup...\cup U_n$. 
Now that I have all this out of the way, I'm not exactly sure where to start. 
 A: Proof of this theorem is not difficult, but long and not so funny. I leave you some hints.


*

*Proving compact $\Rightarrow$ closed and bounded.

*

*Prove that, in a Hausdorff space, every compact subspace is closed. This is not so trivial, I think. Let be $Y$ a compact subspace of a topological space $(X,\tau)$. We prove that $X\setminus Y$ is open. Let be $x_0 \in X\setminus Y$ a generic but fixed point; by separation axiom, there exist (open) neighborhoods $U_y$ for every $y\in Y$ in $X$ and $V_y$ of $x_0$ in $X$ with the propriety that $U_y\cap V_y=\varnothing$. Now, the family $\mathfrak{U}=\{U_y\,|\,y\in Y\}$ is a cover of $Y$; so there is a finite number $k$ of elements $y_1,\ldots,y_k$ such that $\{U_{y_i}\,|\,i=1,\ldots,k\}$ covers $Y$ and such that all elements are disjoint from the respective Hausdorff neighborhood $V_{y_i}$. Then we consider the element $V=V_{y_1}\cap\ldots \cap V_{y_k}$, that is an open neighborhood of $x_0$ in $X\setminus Y$. We can repeat the costruction for every $x_0\in X\setminus Y$, so the thesis. 

*As obvious corollary, in a metric space every compact subsace is closed. So in $\mathbb{R}^n$.

*Show that every compact subspace in a metric space $(X,d)$ is necessarily bounded with respect to metric $d$ (this is easy).


*Proving that closed and bounded $\Rightarrow$ compact.

*

*A first step can be the proof that being bounded for a $Y\subseteq \mathbb{R}^n$ does equal to the existance of a closed pluri-rectangle $Q=[a_1 ,b_1]\times\ldots\times [a_n,b_n]$ that contains $Y$. 

*By a simple version of Tychonoff theorem, that you can prove quite easily, the finite product of compact spaces is compact in the ambient product space. So does the pluri-rectangle as product of compact spaces (in $\mathbb{R}$). 

*You know that $Y$ is closed in $\mathbb{R}^n$, so is also closed in the compact subspace $Q$.

*A closed subspace in a compact space is already compact. This fact has a very simple and straight proof. 

*So you proved that $Y$ is compact.



A very boring part that I switched is the proof that every closed interval in $\mathbb{R}$ is compact. I think you should have seen that. 
