# Assume $f:C \rightarrow \mathbb{R}$ is continuous is also uniformly continuous. Show $C$ is closed.

Let $$C\subset \mathbb{R}^n$$ with the property that any function $$f:C \rightarrow \mathbb{R}$$ that is continuous has to be uniformly continuous. Show $$C$$ must be closed.

Here is my thought process: Suppose, by way of contradiction, C is not closed. Then there exists a sequence $$(x_k)\subset C$$ such that $$(x_k)\rightarrow x*\notin C$$.

At this point I am stuck because I need to find a function $$f$$ that is continuous but not uniformly continuous

Hint: Suppose that there exists a sequence $$(x_n)$$ such that $$x_n\in C, lim_nx_n=x$$ and $$x$$ is not an element of $$C$$. Consider $$f(x)={1\over\|y-x\|}$$ defined on $$C$$, it is continuous but not uniformly continuous.