Artificial intelligent assistant

Investigating continuity of a function defined differently on the rationals and irrationals For a function defined as follows: $f(x) = \begin{cases} 1 & \text{if $x$ is rational} \\\ e^x & \text{if $x$ is irrational} \\\ \end{cases}$ How does one figure out the points at which f is continuous? Is there some kind of heuristic to figuring this out intuitively? To be honest I was a little taken aback by the definition of the function. Naively I thought the function is likely continuous at $0$ since that's when the $e^x$ and $1$ become equal. Are there any other points?

Let $a$ be any real number. There is always a sequence $\langle q_n:n\in\Bbb N\rangle$ of rational numbers converging to $a$, and along this sequence you have $\langle f(q_n):n\in\Bbb N\rangle\to 1$, since all of the $f(q_n)$ are equal to $1$. There is also always a sequence $\langle x_n:n\in\Bbb N\rangle$ of irrational numbers converging to $a$, and along this sequence you have $\langle f(x_n):n\in\Bbb N\rangle=\langle e^{x_n}:n\in\Bbb N\rangle\to e^a$. In order for $f$ to be continuous at $a$, these two limits must be the same. What does that tell you about $a$?

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy b637bf2d8cc1ffaa172c6855712934ed