RankRizz
JEE ADVANCED 2025 · PAPER 1+4HARDTRANSCRIBED

JEE Advanced 2025 Mathematics question — Arrangements with restrictions

Let SS be the set of all seven-digit numbers that can be formed using the digits 0, 1 and 2. For example, 2210222 is in SS, but 0210222 is NOT in SS.

Then the number of elements xx in SS such that at least one of the digits 0 and 1 appears exactly twice in xx, is equal to ________.

SOLUTION

Let a seven-digit number xx contain a0a_0 zeros, a1a_1 ones and a2a_2 twos, so that

a0+a1+a2=7a_0 + a_1 + a_2 = 7 and a0, a1, a2≥0a_0,\,a_1,\,a_2 \ge 0.

Because the first (left-most) digit cannot be 00, we count the admissible arrangements for each triple (a0,a1,a2)(a_0,a_1,a_2) as follows.

Total arrangements with these counts = 7!a0! a1! a2!\dfrac{7!}{a_0!\,a_1!\,a_2!}.
Arrangements whose first digit is 00: fix a zero at the first place and permute the remaining 66 digits, giving 6!(a0−1)! a1! a2!\dfrac{6!}{(a_0-1)!\,a_1!\,a_2!} (this term appears only when a0≥1a_0\ge 1).

Hence the required number for the triple (a0,a1,a2)(a_0,a_1,a_2) is

N(a0,a1,a2)={7!a0! a1! a2!−6!(a0−1)! a1! a2!,a0≥17!a0! a1! a2!,a0=0N(a_0,a_1,a_2)= \begin{cases} \dfrac{7!}{a_0!\,a_1!\,a_2!}-\dfrac{6!}{(a_0-1)!\,a_1!\,a_2!}, & a_0\ge 1\\[6pt] \dfrac{7!}{a_0!\,a_1!\,a_2!}, & a_0=0 \end{cases}

For a0≥1a_0\ge 1, simplifying gives

N(a0,a1,a2)=6!a0! a1! a2! (7−a0)−(1)N(a_0,a_1,a_2)=\dfrac{6!}{a_0!\,a_1!\,a_2!}\,(7-a_0)\qquad -(1)

The problem asks for the count of all numbers in which at least one of the digits 00 or 11 appears exactly twice. We split this into three disjoint cases.

Case 1: a0=2,  a1≠2a_0=2,\;a_1\neq 2

Let the possible values of a1a_1 be 0,1,3,4,50,1,3,4,5 (they must stay within 0≤a1≤50\le a_1\le 5). For each value we compute a2=7−2−a1a_2=7-2-a_1 and use (1)(1).

a1=0,  a2=5:  N=6! (7−2)2! 0! 5!=15a1=1,  a2=4:  N=6! (7−2)2! 1! 4!=75a1=3,  a2=2:  N=6! (7−2)2! 3! 2!=150a1=4,  a2=1:  N=6! (7−2)2! 4! 1!=75a1=5,  a2=0:  N=6! (7−2)2! 5! 0!=15\begin{aligned} a_1=0,&\;a_2=5:&\;N=\dfrac{6!\,(7-2)}{2!\,0!\,5!}=15\\ a_1=1,&\;a_2=4:&\;N=\dfrac{6!\,(7-2)}{2!\,1!\,4!}=75\\ a_1=3,&\;a_2=2:&\;N=\dfrac{6!\,(7-2)}{2!\,3!\,2!}=150\\ a_1=4,&\;a_2=1:&\;N=\dfrac{6!\,(7-2)}{2!\,4!\,1!}=75\\ a_1=5,&\;a_2=0:&\;N=\dfrac{6!\,(7-2)}{2!\,5!\,0!}=15 \end{aligned}

Total for Case 1 = 15+75+150+75+15=33015+75+150+75+15 = 330.

Case 2: a1=2,  a0≠2a_1=2,\;a_0\neq 2

Now a0a_0 can be 0,1,3,4,50,1,3,4,5. Compute a2=7−a0−2a_2=7-a_0-2 and apply the appropriate formula.

a0=0,  a2=5:  N=7!0! 2! 5!=21a0=1,  a2=4:  N=6! (7−1)1! 2! 4!=90a0=3,  a2=2:  N=6! (7−3)3! 2! 2!=120a0=4,  a2=1:  N=6! (7−4)4! 2! 1!=45a0=5,  a2=0:  N=6! (7−5)5! 2! 0!=6\begin{aligned} a_0=0,&\;a_2=5:&\;N=\dfrac{7!}{0!\,2!\,5!}=21\\ a_0=1,&\;a_2=4:&\;N=\dfrac{6!\,(7-1)}{1!\,2!\,4!}=90\\ a_0=3,&\;a_2=2:&\;N=\dfrac{6!\,(7-3)}{3!\,2!\,2!}=120\\ a_0=4,&\;a_2=1:&\;N=\dfrac{6!\,(7-4)}{4!\,2!\,1!}=45\\ a_0=5,&\;a_2=0:&\;N=\dfrac{6!\,(7-5)}{5!\,2!\,0!}=6 \end{aligned}

Total for Case 2 = 21+90+120+45+6=28221+90+120+45+6 = 282.

Case 3: a0=2,  a1=2,  a2=3a_0=2,\;a_1=2,\;a_2=3

Both digits 00 and 11 appear exactly twice.

N=6! (7−2)2! 2! 3!=150N=\dfrac{6!\,(7-2)}{2!\,2!\,3!}=150

Summing all three cases:

330+282+150=762330 + 282 + 150 = 762

Therefore, the required number of seven-digit numbers is
762.

Tagged Arrangements with restrictions. Machine-assigned, so read it as a strong shortlist rather than a verdict.

TopicArrangements with restrictions
TypeNumerical answer