So we have $50$ white balls. We draw balls one after another with returning and if it is white ball we repaint it into red one. Let $X$ be the number of red balls after $20$ drawing. Calculate $\mathbb{E}X$ and $VarX$
I thought to define new random variable such that: $X_i=1$ when $i$-th drawing ball is white and $X_i=0$ when it isn't white. And now we have $X=\sum_{i=1}^{20}X_i$. But I'm afraid that it isn't a good idea because it's very hard to calculate $\mathbb{P}(X_i=1)$
Do you know how to calculate it properly?
Give the balls numbers $1,2,\dots,50$ and let $X_i$ take value $1$ if ball $i$ is painted red after $20$ drawings and let it take value $0$ if not.
Then $X=X_1+\cdots+X_{50}$.
By linearity of expectation and symmetry we find:$$\mathbb EX=50\mathbb EX_1$$ and $$\text{Var}X=\sum_{i=1}^{50}\sum_{j=1}^{50}\text{Cov}(X_i,X_j)=50\text{Var}X_1+50(50-1)\text{Covar}(X_1,X_2)$$
It remains to find $\mathbb EX_1$, $\text{Var}X_1$ and $\text{Covar}(X_1,X_2)$.
edit (I informed you wrong in my comment and this is to repair that):
$$P\left(X_{1}X_{2}=1\right)=$$$$1-P\left(X_{1}=0\vee X_{2}=0\right)=1-P\left(X_{1}=0\right)-P\left(X_{2}=0\right)+P\left(X_{1}=0\wedge X_{2}=0\right)$$
This with $$P\left(X_{1}=0\wedge X_{2}=0\right)=\left(\frac{48}{50}\right)^{20}$$