it is similar to Markov's inequality.
I try to prove it by an example from the book: An urn contains balls numbered $1$ to $N$. Let $X$ be the largest number drawn in $n$ drawing when random sampling with replacement is used. The event $X \le k$ means that each of $n$ numbers drawn is less than or equal to $k$ and therefore $P\{X \le k\}={\big(\frac{k}{N}\big)}^{n}$
but I did not understand how to relate it.
When I try to relate it to Markov's inequality:
If $X$ is a non-negative random variable and $a > 0$, then the probability that $X$ is greater than $a$ is less than the expectation of $X$ divided by $a$.
In my case, $a > 0$
How do I progress?
$1_{X\geq 0}$ is the characteristic function of ${\mathbb R}^{+}$ applied to $X$ and $1_{X< 0}$ is the characteristic function of ${\mathbb R}^{-}$ applied to $X$. $$ E(X)=E(X1_{X<0})+E(X1_{X\geq0})\leq E(X1_{X\geq0}) $$ Because $E(X1_{X<0})<0$
But $X\leq a$, so:
$$ X1_{X\geq0}\leq a1_{X\geq0} $$
Hence:
$$ E(X1_{X\geq0})\leq E(a1_{X\geq0})=aE(1_{X\geq0})=aP(X\geq 0) $$
Thus:
$$ E(X)\leq aP(X\geq 0) $$
In case you don't know:
$$ 1_{X\geq 0}=\begin{cases} 1 \quad if\quad X\geq 0 \\ 0 \quad if\quad X<0\end{cases} $$