Find all continuous functions $f: \mathbb{R} \rightarrow \mathbb{N}$ and all continuous functions $f: \mathbb{N} \rightarrow \mathbb{R}$.
My thinking process went something like this. For the case of $f: \mathbb{R} \rightarrow \mathbb{N}$, if I think about the function in the $xOy$ plane, if we would have any point at which the value would change from one natural number to some other natural number then at that point we would have a jump discontinuity. So every number from the domain $\mathbb{R}$ needs to be mapped to the same natural number in order to have a continuous function. Thus, we need the function to be something like
$$f:\mathbb{R} \rightarrow \mathbb{N} \hspace{1cm} f(x) = n$$
for any $n \in \mathbb{N}$.
In the case of $f: \mathbb{N} \rightarrow \mathbb{R}$ again thinking about the function in the plane $xOy$, the values of the function at two consecutive points $n$ and $n+1$ are not 'tied' together by anything, there's just empty space, so the function is nowhere continuous. Thus, there are no continuous functions $f: \mathbb{N} \rightarrow \mathbb{R}$.
I hope my reasoning is correct. But my real problem is about the writing process of this proof. Obviously I can't write on the paper all of this story that I just came up with. But how can I create a rigorous proof with what I just wrote (with definitions and all of that fluff). Thinking in terms of pictures is nice, but I have to formalize my thinking with definitions, theorems, and the like and in that regard I am lacking terribly. So how can I approach the writing of this proof?