In the last semester, Rikka joined the badminton club.
There are $n$ students in the badminton club, some of them have rackets, and some of them have balls. Formally, there are $a$ students have neither rackets nor balls, $b$ students have only rackets, $c$ students have only balls, and $d$ students have both rackets and balls. $(a+b+c+d=n)$
This week, the club is going to organize students to play badminton. Each student can choose to take part in or not freely. So there are $2^n$ possible registration status.
To play badminton, there must be at least two students who have rackets and at least one students who have balls. So if there aren't enough balls or rackets, the activity will fail.
Now, Rikka wants to calculate the number of the status among all $2^n$ possible registration status which will make the activity fail.