Let the number of children = x

the number of young people = y

the number of old people = z

x + y + z = 100

4x + 2y + 0.25z = 100

There is no third equation, which makes it difficult to solve but we have a condition that x, y and z are all integers as we can't have 1.7 children.

x + y +z = 100

⇒x = 100- y - z

Putting x in second equation

4(100-y-z) + 2y + 0.25z = 100

⇒400 - 4y - 4z + 2y + 0.25 z = 100

⇒2y + 3.75z = 300

⇒z =

Now I will solve by hit-and-trial method keeping certain points in mind.

1. Take only integral values of y.

2. z is an integer. So

is an integer or (300-2y) is a multiple of 3.75.

3. (300-2y) will always be an even integer.

4. An even integer which is a multiple of 3.75 should be an multiple of 30.(This is an important conclusion to reduce the calculation).

5. After you get a answer, check it all conditions are satisfied.

6.Value of z is greater than x and y.

(If you don't understand any point, ask)

take y = 15, so that 2y = 30 is a multiple of 30 and (300-30)=270 is also a multiple of 30.

then z = 270/3.75 = 72

x = 100-72-15 = 13

x+y+z = 100(satified)

4x+2y+0.25z= 100(satisfied)

Answer in the first attempt!!!

So children=13

young people = 15

old people = 72