a-b=(x-(-1),-3-1)=(x+1,-4)
|a-b|=√(x+1)^2+(-4)^2=√(x^2+2x+10)=5
x^2+2x+10=25
x^2+2x-15=0
(x-3)(x+5)=0
x=3 or x=-5