📌 Core Concept
The problem requires counting the number of onto (surjective) functions from set
A to set
B. The formula for the number of onto functions from a set with
m elements to a set with
n elements is given by the inclusion-exclusion principle:
k=0∑n(−1)k(kn)(n−k)m 🔢 Step-by-Step Solution
1
Identify the sizes of sets:
∣A∣=6 and
∣B∣=3.
2
Apply the inclusion-exclusion formula:
For
k=0:
(−1)0(03)(3−0)6=1×1×729=729
For
k=1:
(−1)1(13)(3−1)6=−1×3×64=−192
For
k=2:
(−1)2(23)(3−2)6=1×3×1=3
For
k=3:
(−1)3(33)(3−3)6=−1×1×0=0
3
Sum the results:
729−192+3+0=540.
⚡ 30-Second Shortcut
Alternatively, using Stirling numbers of the second kind S(6, 3) = 90 , the number of onto functions is $3! \times 90 = 6 \times 90 = 540.
🎯 Final Answer
Correct Answer: Option B