Independent observations X1......Xn are such that Xi belongs to {0.,1} and for some 0<theta<1, it is that Pr(Xi=1)=theta.
Let n1 be the number equal to 1.
Find the expected value and variance of n1?
Let's use k instead of $\displaystyle n_{1}$ and p instead of $\displaystyle \theta$ because they are 'more familiar'. The probability to have k ones among n variables is...
$\displaystyle P_{n,k}= a_{n,k}\ p^{k}\ (1-p)^{n-k}$ (1)
... where...
$\displaystyle a_{n,k} = \frac{n!}{k!\ (n-k)!}$ (2)
The expected value of k is then...
$\displaystyle \mu= \sum_{k=0}^{n} k\ P_{n,k}$ (3)
... and the variance...
$\displaystyle \sigma= \sqrt{\sum_{k=0}^{n} (k-\mu}^{2}\ P_{n,k}}$ (4)
Marry Christmas from Serbia
$\displaystyle \chi$ $\displaystyle \sigma$