I got stuck in this question and hoped for a little help.
I have binary array $n \times m$ with $n \leq m$, where each column contains exactly one occurrence of $1.$ Also all the vectors connecting entries of $A$ that contain $1$ are distinct. There is no restriction on the number of $1$'s in a row. I need to prove that $m \le 2n.$
I tried to draw some examples to see how I can reach this inequailty but I can't seem to find any way to do that. If I look at the first index of the vector for instance, I see that I can have maximum $m-1$ so I tried to see for $m>2n$ if I can reach any contradiction but nothing too.
Any help?
Edit:
Adding an example of the matrix for $n=3, m=4$:

Edit 2: The height differences between 1's in adjacent columns is in range:
{-(n-1),...,-1,0,...,n-2,n-1} = V |V|=2n-1 this difference can't repeat so m-1<=2n-1 -> m<=2n
Hint: instead of considering all connecting vectors $(a,b)\in\mathbb Z^2$, it suffices to focus only on these for which $a=1$ - that is, only the ones connecting consecutive columns.
For a given $n\times m$ matrix with a single "1" per column,