Let $M$ be a $n \times n$ matrix over the finite field of two elements that satisfies the following property$\colon$ the total number of 1's in each row coincides with one in each column. In other words, there is a number $N$ such that

The number of non-zero elements in each row of $M$ is $N$.

The number of non-zero elements in each column of $M$ is $N$.

Moreover, the matrix $M$ is such that the sum of *some* two distinct rows of $M$ is a row of $M$ also.

I hope there are non-trivial answers to the following questions.

**Question 1.** Which additional properties the matrix $M$ may has?

**Question 2.** Let $C$ be the binary code obtained as the right kernel of $M$. What can one say about the weight enumerator of $C$? In particular, what are the best bounds on the minimum distance of the code $C$ can be obtained?

I believe that, for example, the algebraic graph theory can be applied to the last question. Unfortunately, I am not a specialist in this theory (as well as in error-correcting codes).

More precisely, the rank of $M$ is less or equal to $q-1$ and $n=\frac{q^2-q}{2}$, $N=\frac{q^2-1}{4}$ where $q$ is an odd prime power.

**UPD 1.** For example, if $q=5$, then we obtain the following matrix$\colon$

$\left(\begin{array}{rrrrrrrrrr} 0 & 1 & 1 & 1 & 1 & 1 & 0 & 1 & 0 & 0 \\ 1 & 0 & 1 & 0 & 1 & 1 & 0 & 0 & 1 & 1 \\ 1 & 0 & 1 & 1 & 0 & 0 & 1 & 1 & 1 & 0 \\ 0 & 1 & 0 & 0 & 0 & 1 & 1 & 1 & 1 & 1 \\ 1 & 1 & 0 & 1 & 0 & 0 & 0 & 1 & 1 & 1 \\ 1 & 1 & 0 & 0 & 1 & 1 & 1 & 0 & 1 & 0 \\ 0 & 0 & 1 & 1 & 1 & 0 & 1 & 0 & 1 & 1 \\ 0 & 0 & 0 & 1 & 1 & 1 & 1 & 1 & 0 & 1 \\ 1 & 1 & 1 & 0 & 1 & 0 & 1 & 1 & 0 & 0 \\ 1 & 1 & 1 & 1 & 0 & 1 & 0 & 0 & 0 & 1 \end{array}\right)$