[proofplan]
We show that the metric topology induced by $|\cdot|_p$ and the $p\mathbb{Z}$-adic topology on $\mathbb{Z}$ have the same open sets by proving that their basic open neighbourhoods coincide. The key identity is that the closed ball of radius $p^{-n}$ centred at $x$ in the $p$-adic metric equals the coset $x + p^n\mathbb{Z}$. Since every open set in either topology is a union of such basic neighbourhoods, the two topologies are identical.
[/proofplan]
[step:Identify the basic open sets in each topology]
In the metric topology induced by $|\cdot|_p$, a basis of open neighbourhoods of $x \in \mathbb{Z}$ consists of the closed balls
\begin{align*}
B_{\leq p^{-n}}(x) := \{y \in \mathbb{Z} : |y - x|_p \leq p^{-n}\}, \qquad n \geq 0.
\end{align*}
These are open in the ultrametric topology because in any ultrametric space, closed balls are clopen (every point inside a closed ball is a centre).
In the $p\mathbb{Z}$-adic topology, a basis of open neighbourhoods of $x \in \mathbb{Z}$ consists of the cosets
\begin{align*}
x + p^n\mathbb{Z} := \{y \in \mathbb{Z} : p^n \mid (y - x)\}, \qquad n \geq 0.
\end{align*}
[guided]
We need to recall how each topology is defined. The metric topology induced by $|\cdot|_p$ is generated by open balls $\{y : |y - x|_p < r\}$ for $r > 0$. Since $|\cdot|_p$ takes values in the discrete set $\{p^{-k} : k \in \mathbb{Z}_{\geq 0}\} \cup \{0\}$ on $\mathbb{Z}$, the open ball of radius $r$ equals the closed ball of radius $p^{-n}$ whenever $p^{-(n+1)} < r \leq p^{-n}$. Thus the closed balls $B_{\leq p^{-n}}(x)$ form a basis.
Why are these closed balls also open? In an ultrametric space $(X, d)$, if $z \in B_{\leq r}(x)$, then for any $y$ with $d(y, z) \leq r$, the ultrametric inequality gives $d(y, x) \leq \max(d(y, z), d(z, x)) \leq r$, so $y \in B_{\leq r}(x)$. This means $B_{\leq r}(z) \subseteq B_{\leq r}(x)$, and in particular $z$ is an interior point. So closed balls are open sets.
The $p\mathbb{Z}$-adic topology is the linear topology on $\mathbb{Z}$ defined by declaring the subgroups $p^n\mathbb{Z}$ ($n \geq 0$) as a basis of neighbourhoods of $0$. A basis of neighbourhoods of an arbitrary point $x$ is then $\{x + p^n\mathbb{Z}\}_{n \geq 0}$.
[/guided]
[/step]
[step:Show that $B_{\leq p^{-n}}(x) = x + p^n\mathbb{Z}$]
For $y \in \mathbb{Z}$, we have
\begin{align*}
|y - x|_p \leq p^{-n} \iff v_p(y - x) \geq n \iff p^n \mid (y - x) \iff y \in x + p^n\mathbb{Z},
\end{align*}
where $v_p$ denotes the $p$-adic valuation on $\mathbb{Z}$ and the equivalence $|y - x|_p = p^{-v_p(y-x)} \leq p^{-n} \iff v_p(y-x) \geq n$ uses the definition of the $p$-adic absolute value: $|a|_p = p^{-v_p(a)}$ for $a \neq 0$, with $|0|_p = 0$.
Therefore $B_{\leq p^{-n}}(x) = x + p^n\mathbb{Z}$ for every $x \in \mathbb{Z}$ and every $n \geq 0$.
[guided]
The $p$-adic absolute value on $\mathbb{Z}$ is defined by $|a|_p = p^{-v_p(a)}$ for $a \neq 0$, where $v_p(a)$ is the largest power of $p$ dividing $a$, and $|0|_p = 0$. The condition $|y - x|_p \leq p^{-n}$ asks that the $p$-adic valuation of $y - x$ is at least $n$, which means $p^n$ divides $y - x$. This is precisely the membership condition for the coset $x + p^n\mathbb{Z}$.
Note that for $y - x = 0$ (i.e., $y = x$), we have $|0|_p = 0 \leq p^{-n}$, and $0 \in p^n\mathbb{Z}$, so $x \in x + p^n\mathbb{Z}$, consistent on both sides.
[/guided]
[/step]
[step:Conclude that the two topologies coincide]
A subset $U \subseteq \mathbb{Z}$ is open in the metric topology if and only if for each $x \in U$ there exists $n \geq 0$ with $B_{\leq p^{-n}}(x) \subseteq U$. By the identity established above, this is equivalent to the existence of $n \geq 0$ with $x + p^n\mathbb{Z} \subseteq U$, which is precisely the condition for $U$ to be open in the $p\mathbb{Z}$-adic topology.
Since both topologies are characterised by the same collection of basic open sets $\{x + p^n\mathbb{Z} : x \in \mathbb{Z},\, n \geq 0\}$, the metric topology induced by $|\cdot|_p$ equals the $p\mathbb{Z}$-adic topology on $\mathbb{Z}$.
[/step]