I am trying to wrap my head around a simple puzzle - building a system of linear equations to solve the following piece from a Thousand and One Nights:
A flock of pigeons alighted upon a tree, some perching upon the upper branches and some upon the lower; those upon the upper branches said to those upon the lower: "If one of you flies up to us our number will be double yours; if one of us flies down to you, our numbers will be equal."
Upper branch has $x$ pigeons, lower has $y$.
Well, if one of the bottom branch flies up, the top branch will have $x+1$ birds and the bottom will have $(y-1)$. The top will have double the bottom, so:
$$x + 1 = 2(y-1)$$
Now, the top branch will have $x-1$ and the bottom $y+1$. The numbers should be equal:
$$x-1 = y+1$$