Consider two sets and . Let f be a function from A to B such that for every element in B, there is at least one element a in A such that . Then, the total number of such functions f is
Solution
Count functions from 6 elements onto 3 elements by inclusion–exclusion:
.