I want to know if there is a formula to find the number of ways to express $N$ as sum of $K$ non-negative numbers such that at least one of those $K$ numbers is odd.
Example: if $N=2$ and $K=3$ the answer is $3$: $(1,1,0)$, $(1,0,1)$, $(0,1,1)$
Also another question :
Let N = 8 and K = 3 I don't want the sets (3,3,2) and (5,1,2) to be counted as different. I mean to say that just the fact the number in the position is odd matters. Then what will be the answer ?