Nowhere continuous function limit

The sequential definition of convergence will always work, as long as whatever limit you have actually converges to the point you are trying to prove it converges to. For this problem you might create two sequences $\{x_n\}, \{y_n\}$ such that $x_n \to 2$, $y_n \to 2$ and $x_n$ is always rational, $y_n$ is always irrational for all $n\in \mathbb{N}$. You can build on that if you think that approach would be easier. Other than that you could try to find a $\delta$ for each piece of $f$ in such a way that whenever $|x-2|<\delta$ then $|f(x)-8|<\varepsilon$ is true, regardless of whether $x$ is irrational of rational. If $x$ is rational, $\delta_r = \frac{\varepsilon}{8}$ (delta for rational $x$) seems like a good choice. If it's irrational, work the absolute values to coax something out. For example, $$\left|(2x^2+8)-16 \right| = \left|2x^2-8 \right| = 2\left|x^2-4 \right| = 2\left|x-2 \right| \left|x+2 \right|$$ In this way, you've made $|x-2|$ appear when $x$ is irrational. Can you bundle up the remaining $2|x+2|$ quantity inside a delta for irrational $x$? I'll call it $\delta_i$. When you're done, take $\text{min}\{\delta_r, \delta_i\} = \delta$ to guarantee $|f(x)-8|<\varepsilon$ will be satisfied for your $x$.


Without using sequences, note that if $0<|x-2|<\delta \leq 1$ then $|2x^2+8-16|<c_1\delta$ and $|8x-16|<c_2\delta$. (I leave it to you to prove this and to identify $c_1,c_2$.) Let $c=\max \{ c_1,c_2 \}$; then if $|x-2|<\delta$ then (regardless of whether $x$ is rational or not) $|f(x)-16|<c\delta$.

There is also an elegant sequence argument, based on splitting into a rational subsequence and an irrational subsequence.