We are given with the variable cost which is:
q = -20s + 400
The selling price is 's'. So, the profit can be represented by:
P = qs - q(12)
Subsituting:
P = (-20s + 400)s - 12 (-20s + 400)
P = -20s^2 + 640s - 4800
To optimize this, we must differentiate the equation and equate it to zero, so:\
dP/ds = -40s + 640 = 0
Solving for s,
s = 16
So, the selling price should be $16 to optimize the yearly profit.