ROSECODE 570
Balls in the boxes
We have several blue balls and red balls and we want to put them into boxes.
The rules for placing the balls into boxes are described below.
- Each box contains at least 2 balls and at most 6 balls.
- Each box contains at least 1 red ball and at most 4 blue balls.
- Balls are different from each other, even they have the same color.
- The order of the box doesn't matter. The order of each ball in the box doesn't matter.
For example, if we have 3 blue balls and 2 red balls. There are 7 different ways to put them into boxes.
(1). {B1,R1}, {B2,B3,R2}
(2). {B1,R2}, {B2,B3,R1}
(3). {B2,R1}, {B1,B3,R2}
(4). {B2,R2}, {B1,B3,R1}
(5). {B3,R1}, {B1,B2,R2}
(6). {B3,R2}, {B1,B2,R1}
(7). {B1,B2,B3,R1,R2}
Let
You are given
Find