Answer:
4 pigs and 8 ducks
Step-by-step explanation:
Let the number of ducks = d
Let the number of pigs =p
There are 12 animals in the barn,
Each pig has 4 legs and each duck has 2 legs.
Therefore:
Total Number of Legs = 4p+2d
We solve the two resulting equations simultaneously.
From the first equation
p=12-d
Substitute p=12-d into 4p+2d=32
4(12-d)+2d=32
48-4d+2d=32
-2d=32-48
-2d=-16
d=8
Recall:
p=12-d=12-8=4
Therefore, there are 4 pigs and 8 ducks on the farm.