Originally Posted by

**Pinkk** Let $\displaystyle f(x)=1$ if $\displaystyle x\in \mathbb{Q}$ and $\displaystyle f(x)=0$ if $\displaystyle x\notin \mathbb{Q}$. Show that $\displaystyle f$ is discontinuous for all $\displaystyle x\in \mathbb{R}$

I know that I should find a sequence $\displaystyle (x_{n})$ where $\displaystyle \lim_{n\to \infty}x_{n} = x$, where $\displaystyle x_{n}$ is rational for even $\displaystyle n$ and irrational for odd $\displaystyle n$ (or vice versa), but I do not know how to find such a sequence.