Exercise · ZW-INTEGER-COMPOSITION-009 · ★★★ Advanced
How many compositions of n=6 have all parts odd?
Choose one option.
Show answer
- A. 8
Exercise · ZW-INTEGER-COMPOSITION-009 · ★★★ Advanced
Choose one option.
Odd parts summing to 6 are 1+1+1+1+1+1, 1+1+1+3, 1+1+3+1, 1+3+1+1, 3+1+1+1, 1+5, 5+1 and 3+3, for a total of 8. The option of 6 counts only some of these arrangements and ignores the ordering of the parts.
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.