# Thread: Functions, Domain & Range

1. ## Functions, Domain & Range

Let "A" be an n-element set and let k E N. How many functions f : A --> {0,1} are the for which there are exactly k elements in "A" with f(a)=1 ?

Note: E = "be a member of" (k E N)
N = Natural numbers

2. If $\displaystyle k>n$ the answer is 0.
If $\displaystyle 1\le k \le n$ then the answer is $\displaystyle \binom{n}{k}$.
You may think of the number of ways to arrange k 1's and (n-k) 0's.

3. Thank you Plato!