At x=1,
L.H.L.→1
R.H.L.→2
L.H.L. ≠R.H.L.
Therefore function is not continuous at x=1 which is why it is not derivable at x=1