Solution (source code)

= Solution

For the observed mean, the one-sided $p$-value is the null <probability> of a <sample mean> at least as large:
$$
p=\mathbb P_{\mu_0}(\overline X\geq\overline x).
$$
Standardization under the null gives
$$
\boxed{p=1-\Phi\bigl(\sqrt n(\overline x-\mu_0)\bigr).}
$$