The first step to this problem is finding the amount of butterfat there are in the 385 gallons milk with 5% of butterfat in it. To do that we need to multiply the percentage by the total amount of milk. This is done below:

There are 19.25 gallons of butterfat on the final mixture, the amount of butterfat from each of the milks we are going to mix need to be equal to that. The first milk contains 8% of butterfat, while the second milk contains 1%. So we have:


Where "x" is the number of gallons from the first milk and "y" is the number of gallons from the second milk. The number of gallons of each milk, when added, should be equal to the number of gallons on the final milk, so we have:

The same is valid for the amount of butterfat.

We have now created a system of equations as shown below:

To solve this system we will multiply the first equation by "-0.01":

Now we need to add both equations.

To find the value of "y" we will use the first equation:

We need 220 gallons from the 8% butterfat milk and 165 gallons from the 1% butterfat milk.