The question says that in a population of 400 flies, only 12 had red eyes.
The total number of fruit flies in this case is 400.
and
The total number of flies having red eyes is 12.
To find out the percentage of fruit flies having red eyes, following formula is used:

So, the percentage of red eye individual is;

Hence, the total percentage of red eye offspring is 3%.