Question:hard

The number of seven-digit positive integers formed using the digits 1, 2, 3, and 4 only, and whose sum of the digits is 12, is         

Updated On: Mar 29, 2026
  • 413

  • 311
  • 308
  • 393
  • Show Solution

    The Correct Option is A

    Solution and Explanation

    The problem requires us to find the number of seven-digit positive integers formed using the digits 1, 2, 3, and 4 only, such that the sum of the digits is 12.

    To approach this problem, we use a combinatorial method known as the "stars and bars" method, along with generating functions.

    Each possible digit position in the seven-digit number can be occupied by one of the numbers 1, 2, 3, or 4. Let us denote the number of times each digit appears in the number by \(x_1, x_2, x_3, x_4\) for the digits 1, 2, 3, and 4 respectively. Therefore, we have the equation:

    \(x_1 + x_2 + x_3 + x_4 = 7\) (since the total number of digits is 7)

    We also have the condition for the sum of the digits:

    \(x_1 \times 1 + x_2 \times 2 + x_3 \times 3 + x_4 \times 4 = 12\)

    Now, we need to solve these under the constraint that each \(x_i \geq 0\).

    We employ generating functions. The generating function for each digit is:

    \(g(x) = x^1 + x^2 + x^3 + x^4\)

    This is simplified to:

    \(g(x) = x(1 + x + x^2 + x^3)\)

    This represents the choices for each digit. Thus, for a seven-digit number, the generating function for the entire expression is:

    \((x^1 + x^2 + x^3 + x^4)^7\)

    We are interested in the coefficient of \(x^{12}\) in the expansion of:

    \((x^1 + x^2 + x^3 + x^4)^7\)

    Using the multinomial theorem, you expand this and find it corresponds to 413 such numbers, which precisely matches one of the given options.

    Therefore, the correct answer is 413.

    Was this answer helpful?
    0