Sets

Problem Author:Tsitsei Pavlo
Problem Setter:Tsitsei Pavlo
Editorial:Tsitsei Pavlo
The answer is $$$(k+1)^n$$$.

For $$$k=1$$$, the answer is $$$2^n$$$, as it is the number of subsets. Consider any $$$k>1$$$. Since the specific set being considered does not matter, and only the number of elements is important, all subsets can be grouped by the number of elements. Then the answer will be $$$\sum_{i=0}^n\binom{n}{i}\cdot f(i,k-1)$$$. Assuming $$$f(i,k-1)=k^i$$$, therefore $$$\sum_{i=0}^n\binom{n}{i}\cdot f(i,k-1)=\sum_{i=0}^n\binom{n}{i}\cdot k^i=(k+1)^n$$$ using the binomial coefficient formula.