Let $X$: "Launch a die until you get the number 5 for the first time", a discrete random variable. I am asked to calculate $P(10<X\leqslant20) $.
Is correct to say...
If $P(10<X\leqslant20)$ then $X$ is in $(10,20]$, and that's equal to $B=(-\infty,20]$ except $A=(-\infty,10]$. But $A$ is included in $B$, so $P(10<X\leqslant20) = P(B-A)=P(B)-P(A)=F_X(20)-F_X(10)$
?
$P(10<X\leqslant20)=P(10<X)+P(X\leqslant20)$ is not true.
You need to consider $P(10<X\leqslant20)$ is the probabilty of $X$ to be an integer in $(10,20]$. But, $P(10<X)+P(X\leqslant20)$ is in general larger.