I have been attempting to solve this HW problem, from Rosenlicht's Introduction to real analysis (pg. 92, 15th problem):
Given a non-empty compact metric space $E$, show that $\max\{d(x,y) \mid x,y \in E \}$ exists.
There was a hint provided with the problem, but I am not sure how to utilize it (something along the lines of trying to find sequences $p_n,q_n$ such the $\lim \;d(p_n,q_n) = \sup\{d(p,q) \mid p,q \in E \}$.
I guess showing that $\max\{d(x,y) \mid x,y \in E\}$ exists is equivalent to showing that $\{d(x,y) \mid x,y \in E\}$ is compact. I tried to do this by defining function $f_{p_0} = d(x,p_0)$ for some point $p_0 \in E$. Since $E$ is compact, $f_{p_0}(E)$ will be compact, therefore closed and bounded and will have a maximum. I can do this over every point in $E$. But, $E$ could be uncountable, so I will end up with uncountably many functions all of whose images would be compact but the maximum I am looking for would be in the union of all the images (closed and bounded), which need not be closed or bounded. So, I am not sure how to procced at this point. Any suggestions?