Today in class my professor said that the sets $[0,1]$ and $[0,2]$ have the same amount of points. I have some questions about this. Since $[0,2] = [0,1] \cup [1,2]$, doesn't it guarantee $[0,2]$ to have more points that $[0,1]$? Also, how exactly can we show $[0,2]$ has as much points as $[0,1]$? Any explanation or keywords that I should Google is appreciated.
Edit: I noticed that the different topology thing is referring to the real number line $[0,1]$ and square with length $1$. Sorry for the confusion.