Continuous $f$ on $[0,1]$ is not one-to-one. We have continuous function $f$ on $[0,1]$ with $f([0,1])=[0,1]\times[0,1]$.

Prove $f$ is never one-to-one?

I know I should show what I tried but I unable to think how to start on this one. I would appreciate some hints so I can update what I tried.

Show that such a function would need to be a homeomorphism (hint: domains and codomain are both hausdorff and compact).  Show that these spaces are not homeomorphic (classic approach: think about removing one point)
