Farmer John looks out onto his farm and counts 16 heads. The only animals are cows and chicken. He then counts 42 legs in all. How many of each animal does farmer John have?

cows 5ducks 11

To determine the number of cows and chickens Farmer John has, we can use a system of equations based on the given information.

Let's assume that the number of cows on Farmer John's farm is represented by 'x', and the number of chickens is represented by 'y'.

We can then set up two equations based on the two given pieces of information:

Equation 1: x + y = 16 (Total number of animal heads)
Equation 2: 4x + 2y = 42 (Total number of animal legs)

To solve this system of equations, we can use either substitution or elimination.

Method 1: Substitution
1. Rearrange Equation 1 to solve for x: x = 16 - y
2. Substitute the value of x in Equation 2: 4(16 - y) + 2y = 42
3. Simplify and solve for y: 64 - 4y + 2y = 42
64 - 2y = 42
-2y = 42 - 64
-2y = -22
y = -22 / -2
y = 11

Substitute the value of y back into Equation 1:
x + 11 = 16
x = 16 - 11
x = 5

Therefore, Farmer John has 5 cows and 11 chickens.

Method 2: Elimination
1. Multiply Equation 1 by 2: 2(x + y) = 2(16) (Equation 3: 2x + 2y = 32)
2. Subtract Equation 3 from Equation 2:
(4x + 2y) - (2x + 2y) = 42 - 32
4x - 2x = 10
2x = 10
x = 10 / 2
x = 5

Substitute the value of x back into Equation 1:
5 + y = 16
y = 16 - 5
y = 11

Therefore, Farmer John has 5 cows and 11 chickens.

In conclusion, Farmer John has 5 cows and 11 chickens on his farm.