how much water at 90 degree fahrenheit must be mixed with 30 gallons of water at 40 degrees fahrenheit so that the resulting temperature of all of the water would be 75 degree fahrenheit

Are we assuming something like

mix 2 L of water at 60° with 2 L of water at 80° we will have 4 L of water at 70° ?

Perhaps a physics teacher could shed some like on this

If this is valid then

90x + 40(30) = 75(x+30)
90x + 1200 = 75x + 2250
15x = 1050
x = 70

70 gallons of the hot water must be added