dist$(x,A)=0$ if and only if $x\in \overline{A}$ (closure of $A$) Let $(X,d)$ be  a metric space and non-empty $A\subset X$. The distance from $x$ to $A$ is defined as $$\mbox{dist}(x,A)=\inf\{d(x,a):a\in A\}$$
I want to show that dist$(x,A)=0$ if and only if $x$ is in the closure of $A$.

(=>): dist$(x,A)=0$ implies $\inf \{d(x,a):a\in A\}=0$. Suppose $x\not\in \overline{A}$, then $x\in X\setminus \overline{A}$, which is an open set. Thus $\exists\epsilon >0$ such that punctured open ball $B(x;\epsilon)\setminus\{x\}= \{y\in X:0<d(x,y)<\epsilon\} \subset X\setminus\overline{A}$. But then dist$(x,A)=\inf\{d(x,a):a\in A\}\ge \inf\{d(x,y):y\in B(x,\epsilon)\setminus\{x\}\}>0$. This is a contradiction! Hence, $x\in \overline{A}$.
(<=): Suppose $x\in \overline{A}$. If $x\in A^\circ$ (the interior of $A$) then $\inf\{d(x,a):a\in A\}=d(x,x)=0$.
  If $x\not\in A^\circ$ then $\exists $ a sequence $(a_k)_k\subset A$ such that $a_k$ converges to $x$. Then, $\forall \epsilon > 0, \exists N\in\mathbb{N}$ such that $k\ge N\implies d(a_k,x)<\epsilon$.
So that dist$(x,A)=\inf\{d(x,a_k)\}=\lim\limits_{k\to\infty} d(x,a_n) = 0$.

Please let me know if my proof is rigorous / correct. I'm not completely sure, think it's better to check.

Your proof is correct, but observe that this problem is really more of a statement about the infimum of a set of real numbers than about topology:
Recall that the infimum $\alpha$ of a nonempty lower-bounded set $S$ of real numbers is the number such that for every integer $n > 0$ there is an element $s_n\in S$ such that
$$
\alpha \le s_n < \alpha + \frac{1}{n}.
$$
So for this problem, if $d(x,A) = 0$, then $\inf\{d(x,y):y\in A\} = 0$. Thus for every $n$, there is an element $y_n\in A$ such that $d(x,y_n) < 1/n$. But this is just the definition of a sequence of points $\{y_n\}$ in $A$ that converges to $x$. Hence $x$ belongs to the closure of $A$.
Conversely, if $x$ lies in the closure of $A$, then $x$ is the limit of a sequence of points $y_n\in A$ such that $y_n\to x$. (If $x\in A$, there is nothing to show.) Translating $y_n\to x$ into a statement about real numbers, we glean that for every $\epsilon>0$, and all $n$ sufficiently large, $d(x,y_n) < \epsilon$, so that $d(x,A)=\inf\{d(x,y):y\in A\} = 0$ by the definition of infimum.
