$$ \mbox{Let}\ x\ \mbox{have pdf}\quad {\rm f}\left(x\right) = {n \choose x}p^{x}\left(1 - p\right)^{n-x} $$
for $x = 0,1,2,\ldots,n$ where $n$ is positive integer constant and $0 < p < 1$ is also a constant.
Find the pdf of $y = n - x$.
I has noticed that $x$ has a binomial distribution. This is the first problem that I run onto discrete case. Can anyone help me with this problem ?, Thank you !.
We have $Y=y$ if and only if $n-X=y$ if and only if $X=n-y$. From the given probability distribution function of $X$, it follows that $$\Pr(Y=y)=\binom{n}{n-y}p^{n-y}(1-p)^{n-(n-y)}=\binom{n}{y}p^{n-y}(1-p)^y.$$
The above is a very mechanical approach. Better, I think, is to note that $X$ is the number of heads when a coin that has probability $p$ of giving head is tossed $n$ times. Then $Y=n-X$ is the number of tails. Since the probability of tail is $1-p$, we have $$\Pr(Y=y)=\binom{n}{y}(1-p)^y p^{n-y}.$$