Exercise · ZW-INTEGER-COMPOSITION-007 · ★★☆ Intermediate
How many compositions of n=6 have exactly 3 parts?
Choose one option.
Show answer
- C. 10
Exercise · ZW-INTEGER-COMPOSITION-007 · ★★☆ Intermediate
Choose one option.
With k=3 we get \(\binom{5}{2}=10\), by choosing 2 separators among 5 gaps. The option of 20 is \(\binom{6}{3}\), which confuses n-1 with n.
A composition of a positive integer n is a way of writing it as an ordered sum of positive integers, where the order of the summands matters.