How many rabbits and chickens are there if were 35 heads 94 legs?

Here's how to solve this classic riddle:

Let:

* `r` = number of rabbits

* `c` = number of chickens

Set up the equations:

* Heads: r + c = 35

* Legs: 4r + 2c = 94 (Rabbits have 4 legs, chickens have 2)

Solve for the variables:

One way to solve is using substitution:

1. Solve for 'r' in the first equation:

r = 35 - c

2. Substitute this value of 'r' into the second equation:

4(35 - c) + 2c = 94

3. Simplify and solve for 'c':

140 - 4c + 2c = 94

-2c = -46

c = 23

4. Substitute the value of 'c' back into either original equation to find 'r':

r + 23 = 35

r = 12

Answer:

There are 12 rabbits and 23 chickens.