Solution (source code)

= Solution

Let $\chi_1$ be the real character associated with the exceptional zero $\beta$. The <prime number theorem in an arithmetic progression with an exceptional zero> gives, uniformly for $x\geq2$ and $(a,q)=1$,
$$
\boxed{
\psi(x;q,a)
=\frac{x}{\varphi(q)}
-\frac{\chi_1(a)x^\beta}{\beta\varphi(q)}
+O\left(
x(\log q)^2
\exp\left[-\frac{c\log x}{\log q+\sqrt{\log x}}\right]
\right).
}
$$
If no exceptional zero exists, the middle term is omitted. The constant $c>0$ is absolute.