In a textbook, the conditional probability $P(A|B)$ is well defined when $P(B)\neq 0$ and is defined as the fraction $\frac{P(A\cap B)}{P(B)}$.
I am not sure about the requirement that $P(B)\neq 0$. If the sample space $\Omega=\mathbb{R}$, $B=\mathbb{Z}$ and $A=\mathbb{N}$, then $P(B)=0$ so $P(A|B)$ is undefined. However, intuitively we understand that $P(A|B)$ should be defined as $0.5$. Is my "intuitive" conditional probability understanding correct, or should we insist that $P(A|B)$ is undefined in this case?