A farmhouse shelters 10 animals. Some are pigs and some are ducks. Altogether there are 36 legs. How many of each animal are there?

Answer:
Let the number of pigs be x. So the number of ducks will be 10 - x.
Since pigs have 4 legs and ducks have 2 legs, then we have
4x + 2(10 - x) = 36. Solve for x:
4x + 20 - 2x = 36
2x + 20 = 36 subtract 20 to both sides
2x = 16 divide by 2 to both sides
x = 8
10 - x = 10 - 8 = 2

Thus, there are 8 pigs and 2 ducks.

Check:
First answer by AmazingMath. Last edit by AmazingMath. Contributor trust: 134 [recommend contributor recommended]. Question popularity: 1 [recommend question].