The correct option is B [−1,1]
|x−1|+|x+1|=2
Case −1: When x≥1
x−1+x+1=2
⇒x=1∈[1,∞)
Case −2: When −1<x<1
−(x−1)+x+1=2
⇒−x+1+x+1=2
⇒2=2
∴ x can have any value as it will satisfy the equation, but here the interval is (−1,1)
i.e. −1<x<1 this whole internal would satisfy case 2.
Case −3: When x≤−1
−(x−1)−(x+1)=2
⇒−x+1−x−1=2
⇒−2x=2
⇒x=−1∈(−∞,−1]
From 1∪2∪3
x∈[−1,1]