If we take $X=\mathbb{R}$ and $Y=Z$ and $E=\mathbb{N}$ i.e. $\{1,2,3,4,5,\cdots\}$ then since for this case $E$ is open in $Y$ (as $Y$ is itself an entire metric space) however there does not exist any open set $G$ in $X$ for this particular set. then how $E$ is open in $Y$.
Pl clarify