Let $C(X)$ be the algebra of continuous functions endowed with the compact-open topology. Notice that the functions $d_x : X \to [0, \infty)$ given by $d_x (y) = \min( d(x,y), 1)$ separate the points of $X$: if $d_x (p) = d_x (q)$ for all $x \in X$, taking $x = p$ gives $d_p(q) = 0$, whence $d(p,q) = 0$. The functions $d_x$ are Lipschitz (with Lipschitz constant $1$). There are 3 cases to examine: - if $d(x,y) \le 1$ and $d(x,z) \le 1$, then $| d_x(y) - d_x(z) | = |d(x,y) - d(x,z)| \le d(y,z)$ by the triangle inequality; - if $d(x,y) \le 1$ and $d(x,z) > 1$ then $$| d_x(y) - d_x(z) | = 1 - d(x,y) \le d(x,z) - d(x,y) \le d(y,z)$$ again by the triangle inequality; similarly for $d(x,y) > 1$ and $d(x,z) \le 1$; - if $d(x,y) > 1$ and $d(x,z) > 1$ then $| d_x(y) - d_x(z) | = | 1 - 1 | = 0 \le d(y,z)$. Remember now that the sum and product with scalars of Lipschitz functions are again Lipschitz, and that the product of *bounded* Lipschitz functions (and the $d_x$ are bounded) is again Lipschitz (of course, the Lipschitz constant changes). Consider the subalgebra $A$ of $C(X)$ generated by the family $(d_x)_{x \in X}$ and the constant function $1$. By the preceding paragraph it will be made only of Lipschitz functions. Using the version of the Stone-Weierstrass theorem for the compact-open topology (Stephen Willard, "General Topology", 1970, p. 293, par. 44B.3), the closure of $A$ is $C(X)$, so you get that not only uniformly continuous, but even Lipschitz functions are dense in $C(X)$