What is a path in a topological space? A path in a topological space X is a continuous function from the closed unit interval [0, 1] into X.
What happens when the topological space is something more simple, for example given $X = \{ 1, 2, 3, 4\},$ consider the topology $\tau = \{ \varnothing, \{ 2 \}, \{1, 2\}, \{2, 3\}, \{1, 2, 3\}, X \}$ of six subsets of $X$.
If I now have a path in the example topological space $(X,\tau)$, what is the respective continuous function? Does it map from time to subsets? How can it be continuous if it jumps discretely from subset to subset?
The concept is very intuitive in e.g. $\mathbb{R}^2$, but not so clear what is meant in this elementary case.
 A: $f:[0, 1]\to X$ defined by $$f(x)=\begin{cases} 1\quad \quad \text{$x\in (0,\frac{1}{6})$} &\\ 2\quad \quad \text{$x\in (\frac{1}{5},\frac{1}{4})$}&\\ 3\quad \quad \text{$x\in (\frac{1}{3},\frac{1}{2})$}&\\ 4\quad \quad \text{otherwise}
\end{cases}$$
Then $f$ is continuous map as pre-image of every open set is open.
$f^{-1}(\{2\}) =(\frac{1}{5},\frac{1}{4})$
$f^{-1}(\{1,2\}) =(0,\frac{1}{6})\cup (\frac{1}{5},\frac{1}{4}) $
$f^{-1}(\{2,3\}) = (\frac{1}{5},\frac{1}{4})\cup (\frac{1}{3},\frac{1}{2}) $
$\begin{align} f^{-1}(\{1,2,3\}) &= (0,\frac{1}{6})\cup(\frac{1}{5},\frac{1}{4})\cup (\frac{1}{3},\frac{1}{2}) \end{align}$
$f^{-1}(X) =[0, 1]$
$f^{-1}(\emptyset ) =\emptyset$
A: Topology involves the abstraction of intuitively clear notions, which is what you're butting up against. The "small changes in input lead to small changes in output" intuition regarding continuity is often useful, but it's much cleaner to think strictly in topological terms here. The $\epsilon$-$\delta$ definition of continuity requires a notion of distance, which means you have to work with metric spaces. You haven't defined either of your spaces as metric spaces.
Try using the abstract, topological definition of continuity: a function $f$ is continuous if the preimage of an open set (in the range topology) is open (in the domain topology).

Note that "open" is a relative concept, i.e. it depends on the specific topology being considered. To drive this point home, consider the function $g:[0, 1]\to X$ defined by $$g(x)=\begin{cases} 1\quad \quad \text{$x\in [0,\frac{1}{4})$} &\\ 2\quad \quad \text{$x\in [\frac{1}{4},\frac{1}{2})$}&\\ 3\quad \quad \text{$x\in [\frac{1}{2},\frac{3}{4})$}&\\ 4\quad \quad \text{$x\in [\frac{3}{4},1]$}
\end{cases}$$
where we think of $[0, 1]$ as having the subspace topology when $\mathbb R$ has the lower limit topology. In this case $g$ is a path, i.e. a continuous function, although it would not be continuous if we had initially thought of $\mathbb R$ as having its regular topology, as was done in the accepted answer.
