Let $g : x \mapsto \displaystyle \prod_{k=1}^n (x_k-x)$. For any $b,x \in \mathbb{R}$, let $$A_b(x)=\begin{pmatrix}x_1+x&a+x&a+x&...&a+x\\ b+x&x_2+x&a+x&...&a+x\\b+x&b+x&x_3+x&...&a+x\\\vdots&\vdots&\vdots&\vdots&\vdots\\b+x&b+x&b+x&...&x_n+x \end{pmatrix}$$
It is easy to see that the function $f : x \mapsto \det(A_b(x))$ is a polynomial function of degree $1$ (you can see this by substracting the first column to all the other columns, and then develop the determinant w.r.t the first column).
But one has directly $\displaystyle f(-a)=g(a)$ and $\displaystyle f(-b)=g(b)$, so for every $x \in \mathbb{R}$, and $b \neq a$, one has
$$f(x)=\dfrac{f(-b)-f(-a)}{-b+a}(x+a)+f(-a) = -\dfrac{g(b) - g(a)}{b-a}(x+a) +g(a)$$
which gives (still for $b \neq a$)
$$\det(A_b(0))=f(0) =g(a) -a\dfrac{g(b) - g(a)}{b-a} $$
Now, since $b \mapsto \det(A_b(0))$ is polynomial, then it is continuous, so $\displaystyle \det(A_a(0))=\lim_{b \rightarrow a} \det(A_b(0))$.
One gets
$$\det(A_a(0))=g(a)-g'(a)a$$
i.e. finally
$$\boxed{\begin{vmatrix}x_1&a&a&...&a\\ a&x_2&a&...&a\\a&a&x_3&...&a\\\vdots&\vdots&\vdots&\vdots&\vdots\\a&a&a&...&x_n \end{vmatrix} = \prod_{k=1}^n (x_k-a) + a \sum_{k=1}^n \prod_{l=1, l\neq k}^n (x_l-a)}$$