Proving a set of points of continuity has only irrational elements. Part a) 
Prove that for any function $f:\mathbb{R} \rightarrow \mathbb{R}$, the set $C_f$ of points of continuity of $f$ 
$$
C_f = \left\{ a \in \mathbb{R}: \forall \epsilon > 0, \exists \delta > 0  \forall x,y \left( |x-a| < \delta \text{ and } |y-a|< \delta \right) \Rightarrow |f(x) - f(y)| < \epsilon \right\}
$$
is $G_\delta$ 
Part b) 
Let $f:\mathbb{R} \rightarrow \mathbb{R}$ be defined as follows:
$$
f(x) = \left\{ 
\begin{array}
 00 & \text{if }x \in \mathbb{R}\setminus\mathbb{Q}\\
\frac{1}{q} & \text{if } $x=\frac{p}{q}, p \in \mathbb{Z}, q\in \mathbb{N} \text{ and } p,q\text{ are coprime}.
\end{array} 
\right.
$$
Show that $C_f = \mathbb{R}\setminus\mathbb{Q}$.
Use part a) to show that it is impossible to define a function $g:\mathbb{R} \rightarrow \mathbb{R}$ with $C_g = \mathbb{Q}$ 

Attempt solution for a)
Let
$$
C_{f_1} = \left\{ a \in \mathbb{R}: \forall \epsilon > 0,  \forall x,y \left( |x-a| < 1 \text{ and } |y-a|< 1 \right) \Rightarrow |f(x) - f(y)| < \epsilon \right\}
$$
and
$$
C_{f_k} = \left\{ a \in \mathbb{R}: \forall \epsilon > 0,  \forall x,y \left( |x-a| < \frac{1}{k} \text{ and } |y-a|< \frac{1}{k} \right) \Rightarrow |f(x) - f(y)| < \epsilon \right\}
$$
We have $C_{f_1} \supseteq C_{f_2} \supseteq \dots \supseteq  C_{f_k} \supseteq C_{f_{k+1}} \supseteq \dots $ and 
$$
C_f = \bigcap_{k=1}^\infty C_{f_k}
$$
so $C_f$ is $G_\delta$ 
Any help on questions a) or b) is appreciated! 
Thank you.

For a), take $\epsilon = \frac{1}{n}$ and define $C_f^n=\{ a \in \mathbb{R} \mid \exists \delta>0, a - \delta < x, y < a + \delta \implies |f(x)-f(y)|< \frac{1}{n}\}$. We have that $C_f^n$ is open because given $a \in C_f^n$ and $a - \delta < b < a + \delta$, we can take $\delta_1=\frac{1}{2}\min(a + \delta - b, b - a + \delta)$ and conclude that $b - \delta_1 < x, y < b + \delta_1 \implies |f(x)-f(y)|< \frac{1}{n}$, i.e., $b \in C_f^n$.
Now note that $\cap_{n \ge 1} C_f^n = C_f$. This concludes a).
The last part of b) follows from Baire's Category Theorem.
