- #1

- 1

- 0

We want to pick 5 numbers out of that, but there is a restriction - the summation of the 5 picked numbers must be 21 or less.

How many different combinations can we get?

The answer is 24 but I would like to know how to work it out (besides the impractical way of listing down all the possibilities in this case there are 462 different combinations, and testing one by one so that it is 21 or less)