Let
$$f(x) = \left\{\begin{array}{ll}
0 & \text{if }x\in\mathbb{Q},\\
1 & \text{if }x\notin\mathbb{Q}.
\end{array}\right.$$
Then $f(x)$ is Borel- (hence Lebesgue-) measurable, since $\mathbb{Q}$ is countable; it is also discontinuous everywhere, hence almost everywhere not continuous.
Regarding the comments made below, we have
Lusin's Theorem. If $f\colon [a,b]\to\mathbb{C}$ is measurable, then for every $\epsilon\gt 0$ there exists a compact $E\subseteq [a,b]$ such that $f|_E$ is continuous and $\mu(E^c)\lt\epsilon$.
This is the best you can hope for, as for instance the characteristic function of a fat Cantor set shows, as noted in this previous question.