Let $n\geq 2$, $A=[a_{ij}]\in Mat_n(\mathbb{R})$ the matrix defined by $a_{ij}=0$ if $i=j$ and $a_{ij}=1$ if $i\not =j$
Calculate $\det(A)$
Proof:
Sylvester's theorem: https://en.wikipedia.org/wiki/Sylvester%27s_determinant_identity
Using Sylvester's determinant theorem, which says that for any rectangular matrices of mutually transposed shapes $A\in\mathrm M_{n,m}(K)$ and $B\in \mathrm M_{m,n}(K)$ one has $$\det(I_n+AB)=\det(I_m+BA).$$
If $N$ is your matrix then $-N=I_n-AB$ where $A\in\mathrm M_{n,1}(K)$ is a one column all-one matrix and $B$ is its transpose. Then $$ \det(N)=(-1)^n\det(-N)=(-1)^n\det(I_1-BA)=(-1)^n(1-n). $$ I need an explanation about one part of the proof Question:
I don't see this step:
$(-1)^n\det(I_1-BA)=(-1)^n(1-n).$