Math Help - Continuous functions

1. Continuous functions

Suppose that f : (a, b) R is continuous and that f(r) = 0 for ever rational number r є (a, b). Prove that f(x) = 0 for all x є (a, b).

2. Hello,

For all $x\in [a,b]$ reals, it exists a sequence of rationals $(r_n)$ such as $r_n\longrightarrow x$.

Since $f$ is continuous then $f(r_n)=0\longrightarrow f(x)$

And so...

3. Very nice- and not at all what I was thinking of. I was thinking of a proof by contradiction. Suppose there exist some a such that $f(a)= b\ne 0$. Let $\epsilon= |b|/2$. Then for all $\delta> 0$, there exist rational x in the interval $(a-\delta, a+ delta)$. For that x, $|x- a|< \delta$ but $|f(x)- f(a)|= |0- b|= |b|> |b|/2= \epsilon$, contradicting the fact that f is continuous.