Let $X$ be a discrete random variable, and $P(X = x)$ is its probability mass function of a binomial experiment.
If I want the probability of obtaining between 5 and 10 successes, I write $P(4<X<11)$.
However, what if I want either between 5 and 10 or between 15 and 20?
I could think of:
$P(4<X<11\vee14<X<21)$
$P(4<X<11\cup14<X<21)$
$P(X=x:4<x<11\vee14<x<21)$
How would one write it and is the use of logical operators acceptable since, in probability experiments, one uses set notation most of the time?
In probability one usually works with events. In essence the probability operator $P$ is defined for sets, i.e. in your case we have the set $A = \{ 4 < X < 11\}$ and the set $B = \{ 14 < X< 21\}$. How the probability operator works is it takes in a set for example $$P( 4 < X < 11 ) = P(A) = P( \{ 4 < X < 11\}),$$ which is all notationally the same. Now using set theory a combination (either) of both events is the union, namely $C :=A \cup B = \{ 4 < X < 11 \} \cup \{ 14 < X < 21\}$. This new set $C$ is precisely the event when A or B happens. Hence in correct notation we have $$ P(C) = P\left(\{ 4 < X < 11 \} \cup \{ 14 < X < 21\}\right). $$ In probability theory one does not use logical operators but only events, in some more basic books it may be $\bf{defined}$ that indeed $$P\left(\{ 4 < X < 11 \} \cup \{ 14 < X < 21\}\right) = P( (4 < X < 11) \lor (14 < X < 21)). $$ Or some variation of the above but this is not typical notation. Notice that I used $\lor$ as this is the logical operator for or.