JEE Main 2025 · 24 January · evening · Numerical answer · +4 / −1

Number of functions f:{1,2, …, 100} →{0,1}, that assign 1 to exactly one of the positive integers less than or equal to 98 , is equal to ________.

Answer and solution

Answer 392

Solution

Maths sir · 3 steps

The condition only controls 1 to 98, so 99 and 100 are free. Count the two parts separately and multiply.

  1. Inputs 1 to 98. Exactly one of these 98 numbers must go to 1, and all the others must go to 0. Choosing which one gets the 1 can be done in 98 ways.
  2. Inputs 99 and 100. The condition says nothing about 99 and 100, so each can go to 0 or 1 freely. That gives 2 × 2 = 4 ways.

    Number of functions = 98 × 2² = 392

  3. So. By the fundamental principle of counting, the number of such functions is 392.

The common slip: 98. Treating 99 and 100 as forced to 0 gives 98. They are free, so you must multiply by 2² = 4.

The idea to keep. Read exactly which inputs a condition restricts. Count the restricted part and the free part separately, then multiply. Every free input adds a factor equal to the size of the codomain.

Answer from the NTA final answer key. Solution by PrepWiser.

Study Permutations & Combinations

Asked about 160 times in JEE Main since 2020. This question is from 2025.