TITLE: Proving that $\det(A) \ne 0$ if $a_{i,i} = 0$ and $a_{i,j} = \pm 1$ for $i \neq j$
QUESTION [14 upvotes]: Let $A$ be an $n\times n$ matrix ($n=2k$, $k \in \Bbb N^*$) such that.
$$a_{ij} =
\begin{cases}
\pm 1,  & \text{if $i \ne j$} \\
0, & \text{if $i=j$}
\end{cases}$$ 
Show that $\det (A) \ne 0$.

P.S. $a_{ij}=\pm 1$ means that it can be $+1$ or $-1$ not necessarily the same for all $a_{ij}$. 
My approach:
I've started with the definition of $\det A$ writing like a permutation sum but it became messy. I also tried Laplace's method but also didn't work. I also tried induction but once $\pm 1$ is aleatory it became tough to deal with.

REPLY [5 votes]: Here's an approach which connects to your original idea of writing out the definition of $\det A$ as a sum over permutations:
If you to this, you get $n!$ terms, each of which is either $+1$, $-1$ or $0$. The terms which are zero are the ones where you include at least one matrix entry from the diagonal, so they correspond exactly to the permutations $\pi$ which have at least one fixpoint (i.e., $\pi(k)=k$ for some $k$).
So the nonzero terms in the sum correspond to the fixpoint-free permutations, also known as derangements. And the number of derangements of $n$ elements, call it $a_n$, is odd if $n$ is even (and even if $n$ is odd), which is easy to prove from the recursion
$$
a_1=0
,\qquad
a_n = n a_{n-1} + (-1)^n
.
$$
So your determinant is the sum of an odd number of $+1$ and $-1$, hence it is itself an odd number, and can't be zero.