Is this statement "a map $f$ is continuous if and only if for any open set $G$, ${f^{ - 1}}(G)$ is still open" true? I am really puzzled by this statement and it has so many different versions in different places. Yesterday I did a homework to prove that a finite function $f$ is continuous if and only if ${f^{ - 1}}(G)$ is open for any open set $G$. Today I see an application of this statement without the restriction of "finite". And I found in a lecture note which says

I am really confused. I want to know if this statement "a map $f$ is continuous if and only if for any open set $G$, ${f^{ - 1}}(G)$ is still open" is true in general? There is no need to impose a restriction like "finite map"? Can you provide a proof or a reference of proof? Thank you!
 A: First, the function $f$ is finite because it's codomain is $R$. If it's codomain was $R \cup \{\infty\}$, then it wouldn't necessarily be finite. See this question for what it means for a function to be finite.
Second, remember what it means for a set to be open relative to another set. In $R^n$, there is an induced topology on a subset $D$ of $R^n$ given by the sets $U \cap D$ where $U$ is open in $R^n$.
In principle, $D$ could be closed. So if you had an open set $U$ and looked at $f^{-1}(U)$, this set could also be closed, yet the function $f$ could still be continuous. The way to reconcile this is to consider the openness of $f^{-1}(U)$ relative to the induced topology on $D$.
For instance, consider $f:[0,1] \to R$ given by $f(x)=x$ and consider $f^{-1}((-2,2))=[0,1]$. The set is closed in $R$, but it is actually open in $[0,1]$. This is how it should be since $f(x)=x$ is still continuous on $[0,1]$.
So the point of the exercise is demonstrate how this reconciliation works. Makes sense?
A: Let $V$ be relatively open/open in $f(D)$, i.e. $V = G \cap f(D)$ where $G$ is open in $\mathbb R^n$. In particular $f^{-1}(G) = f^{-1}(V)$.
Let $y\in V$, then by definition $\exists x_y \in D, f(x_y) = y$. 
Since $f$ is continuous, we know there exists an open ball $B_\delta(x)$ where $f(B_\delta(x)) \subseteq B_\varepsilon(y) \subseteq V$. 
It follows that $f^{-1}(V) = (\bigcup_{y \in V} B_\delta(x) ) \cap D$ (If you don't see it let me know). Union of open balls is open, and hence, $f^{-1}(G) = f^{-1}(V)$ is open.
The other direction is exactly the same except back wards. Continuity gives us $\varepsilon$ for each $\delta$ for the open balls, pre-open mapping gives $\varepsilon$ for each $\delta$ for continuity via pre-mapping of open balls.
The reason I avoided saying that "it's true because topogically that's how we define it", is because the reason we define it in topology is BECAUSE of this property of $\mathbb R^n$. We modelled topology after our intuition of $\mathbb R^n$.
