12 chickens 4 rabbits
There are 5n chickens and 20-3n rabbits, for n = 1,2,3,4,5 or 6.
Let's denote the number of chickens as C and the number of rabbits as R. We can write two equations based on the given information: C + R = 72 (total number of heads) and 2C + 4R = 200 (total number of feet). Solving these equations simultaneously, we find there are 50 chickens and 22 rabbits in the cage.
7 chickens and 11 Rabbits - 7 X 2 (feet per chicken) plus 11 X 4 (feet per rabbit) equals 58
Suppose there are C chickens and R rabbits. Then Feet: 2*C + 4*R = 140 . . . . . (I) Heads: C + R = 50 . . . . . . . . (II) Equation (I) - Equation (II) gives: 2*C + 4*R - 2*C - 2*R = 140 - 2*50 or 2*R = 40 so that R = 20 and then, by (II), C + 20 = 50 so that C = 30. Answer: 20 rabbits and 30 chickens. This assumes, of course, that there are no headless chickens running around!
9 sheeps and 18 chickens
there are 80 goats and 20 chickens.
Here's a Perl script that will answer the problem for any number of heads and feet. sub how_many { print "Number of heads: "; chomp($h = ); print "Number of feet: ";chomp($f = ); $p = $h; $c = 0; while (($p*4 + $c*2) != $f) { $p--; $c++; } } &how_many; print "There are $p pigs and $c chickens.\n"; print "They have $h heads and $f feet.\n"; Number of heads: 27 Number of feet: 78 There are 12 pigs and 15 chickens. They have 27 heads and 78 feet.
12 rabbits 15 ducks
It works out that there are 49 chickens and 15 cows Heads = 49+15 = 64 Feet = 2*(49)+4*(15) = 158
85 chickens
On a farm there are chickens and three-legged-cows. There are total of 49 heads and 130 legs. How many chickens are on the farm?
nothin