3. There are 24 sparrows on three branches. When 4 sparrows flew from the first branch to the second, and 3 sparrows flew from the second to the third, the number of sparrows on all branches became equal. How many sparrows were originally on each branch?
3. 4) $24: 3=8$ (sparrows) - was on each branch after the flight;
2) $8-3=5$ (sparrows) - was on the third branch initially;
3) $8+4=12$ (sparrows) - was on the first branch;
4) $5+12=17$ (sparrows) - was on the first and third branches before the flight;
5) $24-17=7$ (sparrows) - was on the second branch initially.

The problem can be solved in another way. For this, we keep the first three actions the same, and replace the fourth and fifth with the following:
4) $4-3=1$ (sparrows) - was on so much less initially on the second branch;
5) $8-1=7$ (sparrows) - was on the second branch initially.

Answer: initially, 12 sparrows were sitting on the first branch, 7 - on the second, 5 - on the third.