Let g be defined on all of R. If A is a subset of R, define the set g^-1(A) by

g^-1(A)={x in R : g(x) in A}.

Show that g is continuous iff g^-1(O) is open whenever O contained in R is an open set.

well g^-1(O) means g(O) is in A.

Let g be continuous and O be an open subset of R.

Then |x-c|<delta and |g(x)-g(c)|<epsilon

Now I get stuck