Prove f(y) = y for every real number y

Tags:
1. May 8, 2016

Annie B

A function f: R->R is a continuous function such that f(q) = q for every rational number q.
Prove f(y) = y for every real number y.

I know every irrational number is the limit to a sequence of rational numbers. But I not sure how to prove f(y) = y for every real number y. Any ideas?

2. May 8, 2016