This is a question from my homework for a real analysis course. Please hint only.
Let $M$ be a compact metric space. Let $\mathbb{K}$ be the class of non-empty compact subsets of $M$. The $r$-neighbourhood of $A \in \mathbb{K}$ is
$$ M_r A = \lbrace x \in M : \exists a \in A \text{ and } d(x,a) < r \rbrace = \bigcup_{a \in A} M_r a. $$
For $A$, $B \in \mathbb{K}$ define
$$D(A,B) = \inf \lbrace r > 0 : A \subset M_r B \text{ and } B \subset M_r A \rbrace. $$
Show that $\mathbb{K}$ is compact.
(Another part of the question is that if $M$ is connected, then so is $\mathbb{K}$, but this is not assigned).
Many thanks.