Skip to content
Official PYQ · 2015

GATE CS 2015 Set 2 Q54 — Sets, Relations and Functions

Explain with AI
Let XX and YY denote the sets containing 22 and 2020 distinct objects respectively and FF denote the set of all possible functions defined from XX to YY. Let ff be randomly chosen from FF. The probability of ff being one-to-one is ______.
View worked solution

Answer: 0.95

Let the size of the sets be ∣X∣=2|X| = 2 and ∣Y∣=20|Y| = 20.

Step 1: Total number of functions (∣F∣|F|)
Any function f:X→Yf: X \to Y maps each of the 22 elements of XX to any of the 2020 elements of YY.
Total functions=∣Y∣∣X∣=202=400\text{Total functions} = |Y|^{|X|} = 20^2 = 400

Step 2: Number of one-to-one (injective) functions
For a function to be one-to-one, distinct elements in XX must map to distinct elements in YY.
- The first element of XX can be mapped to any of the 2020 elements in YY.
- The second element of XX can then be mapped to any of the remaining 1919 elements in YY.
Number of one-to-one functions=20×19=380\text{Number of one-to-one functions} = 20 \times 19 = 380

Step 3: Probability calculation
Since ff is chosen uniformly at random from FF, the probability that ff is one-to-one is:
P=Number of one-to-one functionsTotal number of functions=380400=1920=0.95P = \frac{\text{Number of one-to-one functions}}{\text{Total number of functions}} = \frac{380}{400} = \frac{19}{20} = 0.95

Free practice · Your answers on this page are not saved.

Published
Report a correction
Keep exploringMore Sets, Relations and Functions questions