CAT 2022 Slot 1QA Question 22

ModulusEasy

Let 0 ≤ a ≤ x ≤ 100 and f(x) = |x - a| + |x - 100| + |x - a - 50|. Then the maximum value of f(x) becomes 100 when a is equal to

Answer & solution

  • A

    0

  • B

    25

  • 50

  • D

    100

Solution

Easy

On the given range ax100a\le x\le 100 two of the moduli open cleanly: xa=xa|x-a|=x-a and x100=100x|x-100|=100-x. They cancel the xx, leaving f(x)=(100a)+xa50f(x)=(100-a)+|x-a-50|. Test each option to see which keeps the maximum at exactly 100100.

1

Simplify on ax100a\le x\le 100:

f(x)=(xa)+(100x)+xa50 f(x)=(100a)+xa50\begin{aligned} &f(x)=(x-a)+(100-x)+|x-a-50|\\ &\Rightarrow\ f(x)=(100-a)+|x-a-50| \end{aligned}
A

a=0a=0: f(x)=100+x50f(x)=100+|x-50|. At x=100x=100, f=150>100f=150\gt 100. Rejected.

B

a=25a=25: f(x)=75+x75f(x)=75+|x-75|. At x=100x=100, f=100f=100 but at e.g. x=100x=100 it is 100100; however the simplified form only holds for xax\ge a, and checking the full range gives values exceeding 100100 near the other end. Rejected.

C

a=50a=50:

f(x)=50+x100for 50x100: x100=100x50 f(x)50+50=100, equality at x=50\begin{aligned} &f(x)=50+|x-100|\\ &\text{for }50\le x\le 100:\ |x-100|=100-x\le 50\\ &\Rightarrow\ f(x)\le 50+50=100,\ \text{equality at }x=50 \end{aligned}

Maximum is exactly 100100. Correct.

D

a=100a=100: the range forces x=100x=100 only, giving f(x)=0+100150=50f(x)=0+|100-150|=50. Maximum is 5050, not 100100. Rejected.

a=50a=\mathbf{50}. Option (c).

CAT 2022 Slot 1 QA Q22: Let 0 ≤ a ≤ x ≤ 100 and f(x) = |x - a| + |x - 100| + |x - a - 50|. Then the maximum value of f(x) bec — Solution | TheCATExam