The correct option is A (−∞,∞)
f(x)=x1+|x|
For x≥0,f(x)=x1+x
For x<0,f(x)=x1−x
Since the function changes its definition at x=0, we need to check for continuity and differentiablity only at x=0
Clearly,
f(0+)=f(0−)=f(0)=0
Hence f(x) is continuous at x=0
Now,
R.H.D.=f′(0+)=limh→0+f(0+h)−f(0)h⇒f′(0+)=limh→0+h1+hh⇒f′(0+)=11+h=1L.H.D.=f′(0−)=limh→0+f(0−h)−f(0)−h
⇒f′(0+)=limh→0+−h1−h−h=1⇒L.H.D.=R.H.D.
So, f(x) is differentiable at x=0
Hence, f(x) for all x∈R