Question 1130534
x grams of the 70% Gold
30-x grams of the 40% Gold


{{{70x+40(30-x)=60*30}}}

-

{{{7x+4(30-x)=180}}}

{{{7x+120-4x=180}}}

{{{3x=180-120}}}

{{{3x=60}}}

{{{x=20}}}

.

.
You are not missing how to get the 40%.  Look again at the assigned variable.  x if for grams of the 70% Gold.  What else did THAT mean?  The problem description itself should help.
-
30-x grams of the 40% Gold
{{{30-20}}}
{{{10}}}--------amount of the 40% Gold alloy