Equivalent definitions of continuity
Let $X$ and $Y$ be two toplogical spaces, and $f:X\to Y$ a function. Then the following are equivalent:
a. $f$ is continuous, i.e For every open set $U$ in $Y$, $f^{-1}(U)$ is an open set in $X$
b. For every closed set $C$ in $Y$, $f^{-1}(C)$ is a closed set in $X$
c. For any $p\in X$ the following condition holds:
For each open set $V$ in $Y$ containing $f(p)$ there is an open set $U$ in $X$ containing $p$, such that $f(U)\subseteq V$.
I have proven $a\implies b$. I want to show that $b\implies c$ and $c\implies a$.
$b\implies c$
Let $p\in X$
Suppose $V$ is an open set containing $f(p)$ in $Y$.
Then $V^c$ is closed and $f(p)\not\in V^c$. thus $p\not\in f^{-1}(V^c)$
by assumption of proposition $c.$, $f^{-1}(V^c)$ is closed in $X$
And since $f^{-1}(V^c)=[f^{-1}(V)]^c$, if $p\not\in [f^{-1}(V)]^c$ then $p\in f^{-1}(V)$
and since $[f^{-1}(V)]^c$ is closed in $X$, $f^{-1}(V)$ is open in $X$.
And $f(f^{-1}(V)\subseteq V$
as required.
$c\implies a$
Let $V\subseteq Y$ be open. So that every $y\in V$ either $y=f(p)$ for some $p\in X$ or $f^{-1}(y)$ is empty, in which case it's preimage is the empty set, which is open in $X$. So we only need to show that the preimage of the elements $f$ maps to are open.
then for every $p\in f^{-1}(V)$ there exists an open set $U$ in $X$ such that $f(U)\subseteq V$.
then $U\subseteq f^{-1}(V)$
thus for every $p\in f^{-1}(V)$ there is an open set in $X$ such that $U\subseteq f^{-1}(V)$ thus $f^{-1}(V)$ is open.
I'm mostly unsure of whether I've done $c\implies a$ correctly because I want to start with an arbitrary open set in $Y$ but $c.$ uses points from $X$ and their image. So I have an issue where I take an open set in $Y$ but since $f$ doesn't need to be surjective, I have points that have no preimage under $f$.
c) to a) doesn't need any consideration of surjectivity or not: let $V$ be open in $Y$ and let $U=f^{-1}[V]$. Let $x \in U$ be arbitrary (there could be none, but that doesn't invalidate the argument!). Then by definition $f(x) \in V$ so c) gives us an open $U_x$ such that $f[U_x] \subseteq V$. Note that the latter implies $U_x \subseteq f^{-1}[V]=U$. Then $$U = \bigcup \{U_x: x \in U\}$$ which is open as a union of open sets. (each $p \in U$ is in its "own" $U_p$ for one inclusion, and each $U_x \subseteq U$, for the other inclusion).
b) to c) is fine, though a bit clumsy because you have to take complements, it's easier directly from a): just take $U=f^{-1}[V]$); equivalence of a) and b) is easy both ways using $f^{-1}[Y\setminus A] = X\setminus f^{-1}[A]$ for all $A \subseteq Y$, in essence.