Mathematics (JEE)Very hardCodeforces Div2 D
How many functions f from {1, 2, 3, 4, 5} to {1, 2, 3} satisfy f(1) = 1 and f is onto?
- A. 81
- B. 150
- C. 50
- D. 49
Correct answer: C. 50
With f(1) = 1 fixed, f(2),...,f(5) must hit both 2 and 3; inclusion-exclusion gives 81 - 2*16 + 1 = 50.
Practise more Permutations, Combinations and Probability questionsPermutations, Combinations and Probability: notes and key points
More Permutations, Combinations and Probability questions
- In how many ways can 6 distinct balls be placed into 4 distinct boxes so that no box contains exactly one ball? (Boxes may be empty.)
- What is C(10000, 2500) mod 7, where 7 is prime?
- For how many k from 0 to 1000 is C(1000, k) NOT divisible by 3?
- What is the exponent of 3 in the prime factorisation of C(100, 50)?
- What is C(60, 30) mod 5, where 5 is prime?
- For how many k from 0 to 50 is C(50, k) divisible by 4?