Use the definition of compact set to prove the uniform continuity on compact sets. The question is: Recall the theorem 


  A function that is continuous on a compact set $K$ is uniformly continuous on $K$.


Provide a proof by the definition 


  $K\subset R$ is compact if every open cover of $K$ has a finite subcover.


Can someone tell me how to solve this question?
This is a well known theorem, whose proof you can find in any analysis textbook, so I'll just give a sketch. 

Suppose $f : A \to \mathbb{R}$ is a continuous function and that $A \subset \mathbb{R}$ is compact. 

To use compactness, we need an open cover. Fix $\epsilon &gt; 0$. For each $x \in A$, choose $\delta(x) &gt; 0$ such that $y \in A$ and $|x-y| &lt; \delta(x)$ implies $|f(x) - f(y)|&lt; \epsilon$.

Define $N(x) = \{y \in A : |x - y| &lt; \delta(x)\}$. These $N(x)$ form an open cover of $A$. Use compactness to choose a subcover $N(x_i)$. Take $\delta = \frac{1}{2} \min_i \delta(x_i)$. Suppose two points $x,y$ are $\delta$ close. Argue that $x$ is $\delta$ close to some $x_i$, and that $y$ has to be $\delta(x_i)$ close to that same $x_i$. What can you conclude about the distance between $f(x), f(y)$ and $f(x_i)$?
This is a well known theorem, whose proof you can find in any analysis textbook, so I'll just give a sketch. 

Suppose $f : A \to \mathbb{R}$ is a continuous function and that $A \subset \mathbb{R}$ is compact. 

To use compactness, we need an open cover. Fix $\epsilon &gt; 0$. For each $x \in A$, choose $\delta(x) &gt; 0$ such that $y \in A$ and $|x-y| &lt; \delta(x)$ implies $|f(x) - f(y)|&lt; \epsilon$.

Define $N(x) = \{y \in A : |x - y| &lt; \delta(x)\}$. These $N(x)$ form an open cover of $A$. Use compactness to choose a subcover $N(x_i)$. Take $\delta = \frac{1}{2} \min_i \delta(x_i)$. Suppose two points $x,y$ are $\delta$ close. Argue that $x$ is $\delta$ close to some $x_i$, and that $y$ has to be $\delta(x_i)$ close to that same $x_i$. What can you conclude about the distance between $f(x), f(y)$ and $f(x_i)$?