

More impressively, you can have function that is continuous, but you cannot find a connected path on it (i.e. not path connected). In plain words, if anyone told you “a function is continuous when you can draw it without lifting your pen”. They have lied to you.
You are misrepresenting an analogy as a lie. Besides that, in the context where the claim is typically made, the analogy is still pretty reasonable and your example is just plain wrong.
People are talking about continuous maps on subsets of R into R with this analogy basically always (i.e., during a typical calc 1 or precalc class). The only real issue are domain requirements in such a context. You need connectedness in the domain or else you’re just always forced into lifting your pen.
There are a couple other requirements you could add as well. You might also want to avoid unbounded domains since you can’t physically draw an infinitely long curve. Likewise you might want to avoid open endpoints or else things like 1/x on (0,1] become a similar kind of problem. But this is all trivial to avoid by saying “on a closed and bounded interval” and the analogy is still fairly reasonable without them so long as you keep the connectedness requirement.
For why your example is just wrong in such a context, say we’re only dealing with continuous maps on a connected subset of R into R. Recall the connected sets in R are just intervals. Recall the graph of a function f with domain X is the set {(x,f(x)) : x is in X}. Do you see why the graph of such a function is always path connected? Hint: Pick any pair of points on this graph. Do you see what path connects those two points?
Once you want to talk about continuous maps between more general topological spaces, things become more complicated. But that is not within the context in which this analogy is made.
It’s also false. Take any pair of points on the graph of sin(1/x) using the domain (0,1] that you just gave. Then we can write these points in the form (a,sin(1/a)), (b,sin(1/b)) such that 0 < a < b without loss of generality. The map f(t)=(t,sin(1/t)) on [a,b] is a path connecting these two points. This shows the graph of sin(1/x) on (0,1] is path connected.
This same trick will work if you apply it to the graph of ANY continuous map from a connected subset of R into R. This is what my graph example was getting at.
The “topologists sine curve” example you see in pointset topology as an example of connected but not path connected space involves taking the graph you just gave and including points from its closure as well.
Think about the closure of your sin(1/x) graph here. As you travel towards the origin along the topologists sine curve graph you get arbitrarily close to each point along the y-axis between -1 and 1 infinitely often. Why? Take a horizontal line thru any such point and look at the intersections between your horizontal line and your y=sin(1/x) curve. You can make a limit point argument from this fact that the closure of sin(1/x)'s graph is the graph of sin(1/x) unioned with the portion of the y-axis from -1 to 1 (inclusive).
Path connectedness fails because there is no path from any one of the closure points you just added to the rest of the curve (for example between the origin and the far right endpoint of the curve).
A better explanation of the details here would be in the connectedness/compactness chapter in Munkres Topology textbook it is example 7 in ch 3 sec 24 pg 157 in my copy.
This is fine. I stated boundedness as an additional assumption one might require for pragmatic reasons. It’s not mandatory. But it’s easy to imagine somebody trying to be clever and pointing out that if we allow the domain or range to be unbounded we still have problems. For example you literally cannot draw the identity function in full. The identity map extends infinitely along y=x in both directions. You don’t have the paper, drawing utensils or lifespan required to actually draw this.