-2

$P = \binom{N}{0}-\binom{N}{1}+\binom{N}{2}-\binom{N}{3}+ \dotsb + (-1)^N\binom{N}{N}$

I can calculate the value of this equation manually, but there any direct formula for calculating the value of this equation? Can anyone please help?

Swatak
  • 141

1 Answers1

5

Assuming you mean $C(n,k)=\binom{n}{k}=\frac{n!}{k!(n-k)!}$, then you now from the binomial theorem that $$(a+b)^n=\sum_{k=0}^{n} \binom{n}{k} a^kb^{n-k}.$$ Now set $a=1$ and $b=-1$.

Elmar Zander
  • 1,625