Let $HAUSS$ be the category of all Hausdorff spaces and $i:\mathbb{Q}\rightarrow \mathbb{R}$ be the inclusion map. I am studying a book on Homology theory. It is mentioned there, that the map $i$ is monomorphism as well as epimorphism because $\mathbb{Q}$ is dense in $\mathbb{R}$. But it is not an isomorphism.
My question is that, it can be clearly seen that $i$ is not an homeomorphism (hence isomorphism) but how can we say that $i$ is an epimorphism using the densness of $\mathbb{Q}$. Where in category theory a map $f$ will be an epimorphism if it can be right cancelled.