This might be a very simple question. But I was going through this lecture where it is mentioned that
If I have n-1 neighbors and there is a probability p of having an edge with a neighbor. Then the average degree of any node is given by (n-1)*p. This is fine I get it
But how come the variance of degree is (n-1)p(1-p). I didn't get how this variance was derived.