everything look ok with these?
Lebesgue's Number Lemma. Let $K$ be a compact set in a metric space $(X,d)$. Suppose that $\mathscr C = \{C_\alpha\}_{\alpha \in A}$ is an open cover of $K$. Then there exists $\lambda>0$ so that for every $p \in K$ we have $B(\,p, \lambda) \subseteq C_\alpha$ for some $\alpha \in A$.
Proof. Since $\mathscr C$ covers $K$, for each point $p \in K$ there exists a positive number $2r_{p}>0$ so that $B(\,p,2r_{p}) \subseteq C_{\alpha_p}$ for some $\alpha_p \in A$ (metric space definition of an open set). So $B(\,p,r_{p}) \subseteq C_{\alpha_p}$ because $B(\,p,r_{p}) \subseteq B(\,p,2r_{p})$. Since the collection of open sets $\{B(\,p,r_{p})\}_{p \in K}$ covers $K$, it admits a finite subcover which we write as \begin{equation}B(\,p_1,r_{1}), B(\,p_2,r_{2}), \ldots, B(\,p_j,r_{j}) \;\text{ (definition of a compact set)}. \end{equation} Set $\lambda = \min \{r_1, r_2, \ldots, r_j\}$. Let $p \in K$. Then $p \in B(\,p_i,r_{i})$ for some $1 \leq i \leq j \;$ since $\{B(\,p_n,r_{n})\}_{n=1}^j$ covers $K$. Suppose $q \in B(\, p, \lambda)$. By the triangle inequality, \begin{aligned}d(\,p_i, q) &\leq d(\,p_i, p)+d(\,p,q) \\&=r_i \,+\, \lambda \\&\leq 2r_i. \end{aligned} Therefore $q \in B(\,p_i,2r_{i})$. And so we have shown that $B(\, p, \lambda) \subseteq B(\,p_i,2r_{i}) \subseteq C_{\alpha_i}$.
Theorem. Let $M_1=(X_1,d_1)$ and $M_2=(X_2,d_2)$ be metric spaces. Let $K \subseteq X_1$ be a compact set in $M_1$. If $\,f:X_1 \to X_2$ is continuous on $X_1$, then $f$ is uniformly continuous on $K$.
Proof. Suppose $f:X_1 \to X_2$ is continuous on $X_1$. Let $\varepsilon>0$ be given. For each $p \in K$ the set $f^{-1}\left(B_{d_2} \left(\,f(p), \varepsilon\right)\right)$ is open in $M_1$ (definition of a continuous function). Clearly $\underset{p \in K}\bigcup f^{-1}\left(B_{d_2} \left(\,f(p), \frac{1}{2}\varepsilon\right)\right)$ contains $K$. Since the collection of open sets $\big\{ f^{-1}\left(B_{d_2} \left(\,f(p), \frac{1}{2}\varepsilon\right)\right) \big\}_{p \in K}$ covers $K$, there exists $\lambda>0$ so that for every $p \in K$ we have $B_{d_1}(\,p, \lambda) \subseteq f^{-1}\left(B_{d_2}\left(\,f(x), \frac{1}{2}\varepsilon\right)\right)$ for some $x \in K$ (Lebesgue's Number Lemma). So if $p,q \in K$ and $d_1(\,p,q)<\lambda$, then \begin{aligned}d_2\left(\,f(p), f(q)\right) &\leq d_2\left(\,f(p), f(x)\right)+d_2\left(\,f(x), f(q)\right) \\&<\frac{\varepsilon}{2} \,+\, \frac{\varepsilon}{2} \\&=\varepsilon. \end{aligned}