(N/A) For a continuous charge distribution,the electric potential $V$ at a point $P$ with position vector $\vec{r}$ is given by the integral of the potential contributions from infinitesimal charge elements $dq$.
$1$. For linear charge distribution:
$V = k \int_{L} \frac{\lambda dl}{|\vec{r} - \vec{r}'|}$
where $\lambda$ is the linear charge density,$dl$ is the length element,and $\vec{r}'$ is the position vector of the charge element.
$2$. For surface charge distribution:
$V = k \int_{S} \frac{\sigma dS}{|\vec{r} - \vec{r}'|}$
where $\sigma$ is the surface charge density and $dS$ is the area element.
$3$. For volume charge distribution:
$V = k \int_{V} \frac{\rho dV}{|\vec{r} - \vec{r}'|}$
where $\rho$ is the volume charge density and $dV$ is the volume element.
In all expressions,$k = \frac{1}{4\pi\epsilon_0}$ is Coulomb's constant.