huh, now I realised why I was confused. The full definition was 'A function $f:(X,T_X)\rightarrow(Y,T_Y)$ is continuous on $X$ iff $f^{-1}$ is open for each $U\subset Y$'.
I was thinking of $Y$ as the target set, which would be $\{0,1\}$ in my example, but then since every $U$ needs to be taken out of that, I wasn't able to get that larger subset of Leslie's $(\infty,\frac{1}{2})$. Come to think of it, is it even compatible with the definition?