# Of Balls in Bins in Different Sections with Caps

Problem:

There are $19$ bins: $7, 5, 7$ in the left, centre and right sections respectively.
There are $8$ balls, some or all of which are to be put into these bins with the following conditions:
(1) A bin can only take $1$ ball.
(2) There can be at most $4$ balls in the left section. Similarly for the right section.
(3) Not all of the balls have to be put in bins.

How many different ways are there of doing this?

My attempt:

Let $i,j,r$ represent the number of balls in the left, right and centre sections respectively.

First we count the number of ways $i\;(\le 4)$ balls can be placed in the $7$ left bins.
Then we do the same for the $j\;(\le 4)$ balls for the right bins.
After doing this the number of leftover balls is $8-i-j$.
We then count the number of ways to place $r\;(\le 8-i-j)$ balls into the centre bins.

The number of combinations required is given by: $$\sum_{i=0}^4 \binom 7i\sum_{j=0}^4\binom 7j\sum_{r=0}^{\min(5,8-i-j)}\binom 5r$$

Questions:

Is this approach and formula correct?
If so, is there an alternative approach giving a shorter formulation?
If not, then what is the correct approach and answer?